Skip to content

Commit

Permalink
updated vezgo functions, removed unnecessary vezgo functions
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronk-bixly committed Apr 28, 2022
1 parent d10e0a1 commit 57c251c
Show file tree
Hide file tree
Showing 11 changed files with 99 additions and 210 deletions.
24 changes: 0 additions & 24 deletions src/common/rest/get-vezgo-account/index.ts

This file was deleted.

24 changes: 0 additions & 24 deletions src/common/rest/get-vezgo-insight/index.ts

This file was deleted.

24 changes: 0 additions & 24 deletions src/common/rest/get-vezgo-user-accounts/index.ts

This file was deleted.

24 changes: 0 additions & 24 deletions src/common/rest/get-vezgo-user-transactions/index.ts

This file was deleted.

27 changes: 10 additions & 17 deletions src/common/rest/index.ts
Expand Up @@ -4,14 +4,11 @@ import * as postClient from './post-user';
import * as accounts from './accounts';
import * as getCountries from './get-countries';
import * as postCountry from './post-country';
import * as getVezgoInsight from './get-vezgo-insight';
import * as postVezgoInsight from './post-vezgo-insight';
import * as postVezgoAccounts from './post-vezgo-accounts';
import * as getVezgoAccount from './get-vezgo-account';
import * as getVezgoUserAccounts from './get-vezgo-user-accounts';
import * as postVezgoTransactions from './post-vezgo-transactions';
import * as getVezgoUserTransactions from './get-vezgo-user-transactions';
import * as getVezgoTransaction from './get-vezgo-transaction';

import * as getVezgoProviders from './vezgo/get-providers';
import * as getVezgoLink from './vezgo/get-link';
import * as storeVezgoAccount from './vezgo/store-account';

import * as getPlaidAccount from './plaid/get-plaid-account';
import * as getPlaidLinkToken from './plaid/get-plaid-link-token';
import * as getPlaidTransaction from './plaid/get-plaid-transaction';
Expand All @@ -20,8 +17,9 @@ import * as listPlaidTransaction from './plaid/list-plaid-transactions';
import * as getPlaidAccessToken from './plaid/get-plaid-access-token';
import * as savePlaidAccounts from './plaid/save-plaid-accounts';
import * as savePlaidTransaction from './plaid/save-plaid-transactions';

import * as postUser from './post-user';
import * as getProductInterests from './get-product-interests'
import * as getProductInterests from './get-product-interests';

export interface Parameter {
key: number;
Expand All @@ -45,14 +43,9 @@ export const masaRestClient = {
accounts,
getClient,
postClient,
getVezgoInsight,
postVezgoInsight,
postVezgoAccounts,
getVezgoAccount,
getVezgoUserAccounts,
postVezgoTransactions,
getVezgoUserTransactions,
getVezgoTransaction,
getVezgoProviders,
getVezgoLink,
storeVezgoAccount,
getPlaidAccount,
getPlaidLinkToken,
getPlaidTransaction,
Expand Down
35 changes: 0 additions & 35 deletions src/common/rest/post-vezgo-accounts/index.ts

This file was deleted.

24 changes: 0 additions & 24 deletions src/common/rest/post-vezgo-insight/index.ts

This file was deleted.

35 changes: 0 additions & 35 deletions src/common/rest/post-vezgo-transactions/index.ts

This file was deleted.

43 changes: 43 additions & 0 deletions src/common/rest/vezgo/get-link/index.ts
@@ -0,0 +1,43 @@
import { MethodMetadata } from '..';
import { Headers } from '../../helpers/axios';
import { useRestCall } from '../../helpers/rest-calls';

const path = 'vezgo-connect/:userProfileId/:provider';

export function useMethod({ pathParameters, body }: any) {
const { data, error, loading, getData } = useRestCall({
pathParameters,
headers: Headers,
body,
metadata,
});
return { data, error, loading, getData };
}

const parameters: Parameter[] = [
{
key: 1,
name: 'userProfileId',
description: 'User ID',
required: 'yes',
default: '',
dataType: 'string',
},
{
key: 2,
name: 'provider',
description: 'Provider Name',
required: 'yes',
default: '',
dataType: 'string',
},
];

export const metadata: MethodMetadata = {
author: 'Aaron Knott',
authorPicture: '',
description: 'Get a Vezgo Link for a specific provider',
name: path,
method: 'GET',
parameters,
};
Expand Up @@ -2,7 +2,7 @@ import { MethodMetadata } from '..';
import { Headers } from '../../helpers/axios';
import { useRestCall } from '../../helpers/rest-calls';

const path = 'vesgo-transactions/:userProfileId';
const path = 'vezgo-providers/';

export function useMethod({ pathParameters, body }: any) {
const { data, error, loading, getData } = useRestCall({
Expand All @@ -15,9 +15,9 @@ export function useMethod({ pathParameters, body }: any) {
}

export const metadata: MethodMetadata = {
author: 'Gabriela Golmar',
author: 'Aaron Knott',
authorPicture: '',
description: 'This is our get vezgo transaction',
description: 'Get a list of all providers and logos',
name: path,
method: 'GET',
parameters: [],
Expand Down
43 changes: 43 additions & 0 deletions src/common/rest/vezgo/store-account/index.ts
@@ -0,0 +1,43 @@
import { MethodMetadata } from '..';
import { Headers } from '../../helpers/axios';
import { useRestCall } from '../../helpers/rest-calls';

const path = 'store-account/';

export function useMethod({ pathParameters, body }: any) {
const { data, error, loading, getData } = useRestCall({
pathParameters,
headers: Headers,
body,
metadata,
});
return { data, error, loading, getData };
}

const parameters: Parameter[] = [
{
key: 1,
name: 'code',
description: 'Vezgo Account ID',
required: 'yes',
default: '',
dataType: 'string',
},
{
key: 2,
name: 'institution',
description: 'Vezgo Account Name',
required: 'yes',
default: '',
dataType: 'string',
},
];

export const metadata: MethodMetadata = {
author: 'Aaron Knott',
authorPicture: '',
description: 'Store account credentials ',
name: path,
method: 'POST',
parameters,
};

0 comments on commit 57c251c

Please sign in to comment.