refactor: Use generateAuthUrl method instead of createAuthData
This commit is contained in:
@@ -1,9 +0,0 @@
|
||||
import { gql } from '@apollo/client';
|
||||
|
||||
export const CREATE_AUTH_DATA = gql`
|
||||
mutation CreateAuthData($input: CreateAuthDataInput) {
|
||||
createAuthData(input: $input) {
|
||||
url
|
||||
}
|
||||
}
|
||||
`;
|
9
packages/web/src/graphql/mutations/generate-auth-url.ts
Normal file
9
packages/web/src/graphql/mutations/generate-auth-url.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
import { gql } from '@apollo/client';
|
||||
|
||||
export const GENERATE_AUTH_URL = gql`
|
||||
mutation generateAuthUrl($input: GenerateAuthUrlInput) {
|
||||
generateAuthUrl(input: $input) {
|
||||
url
|
||||
}
|
||||
}
|
||||
`;
|
@@ -3,7 +3,7 @@ import { UPDATE_CONNECTION } from './update-connection';
|
||||
import { VERIFY_CONNECTION } from './verify-connection';
|
||||
import { RESET_CONNECTION } from './reset-connection';
|
||||
import { DELETE_CONNECTION } from './delete-connection';
|
||||
import { CREATE_AUTH_DATA } from './create-auth-data';
|
||||
import { GENERATE_AUTH_URL } from './generate-auth-url';
|
||||
|
||||
type Mutations = {
|
||||
[key: string]: any;
|
||||
@@ -15,7 +15,7 @@ const mutations: Mutations = {
|
||||
verifyConnection: VERIFY_CONNECTION,
|
||||
resetConnection: RESET_CONNECTION,
|
||||
deleteConnection: DELETE_CONNECTION,
|
||||
createAuthData: CREATE_AUTH_DATA,
|
||||
generateAuthUrl: GENERATE_AUTH_URL,
|
||||
};
|
||||
|
||||
export default mutations;
|
||||
|
Reference in New Issue
Block a user