mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-16 17:30:06 +00:00
Finish preliminary Vault integration, made docs for Vault and Checkly
This commit is contained in:
@@ -1,10 +1,12 @@
|
||||
import SecurityClient from '@app/components/utilities/SecurityClient';
|
||||
|
||||
interface Props {
|
||||
workspaceId: string | null;
|
||||
integration: string | undefined;
|
||||
accessId: string | null;
|
||||
accessToken: string;
|
||||
workspaceId: string | null;
|
||||
integration: string | undefined;
|
||||
accessId: string | null;
|
||||
accessToken: string;
|
||||
url: string | null;
|
||||
namespace: string | null;
|
||||
}
|
||||
/**
|
||||
* This route creates a new integration authorization for integration [integration]
|
||||
@@ -15,13 +17,17 @@ interface Props {
|
||||
* @param {String} obj.workspaceId - id of workspace to authorize integration for
|
||||
* @param {String} obj.integration - integration
|
||||
* @param {String} obj.accessToken - access token to save
|
||||
* @param {String} obj.url - URL of the Vault instance
|
||||
* @param {String} obj.namespace - Vault-specific namespace param
|
||||
* @returns
|
||||
*/
|
||||
const saveIntegrationAccessToken = ({
|
||||
workspaceId,
|
||||
integration,
|
||||
accessId,
|
||||
accessToken
|
||||
accessToken,
|
||||
url,
|
||||
namespace
|
||||
}: Props) =>
|
||||
SecurityClient.fetchCall(`/api/v1/integration-auth/access-token`, {
|
||||
method: 'POST',
|
||||
@@ -32,7 +38,9 @@ const saveIntegrationAccessToken = ({
|
||||
workspaceId,
|
||||
integration,
|
||||
accessId,
|
||||
accessToken
|
||||
accessToken,
|
||||
url,
|
||||
namespace
|
||||
})
|
||||
}).then(async (res) => {
|
||||
if (res && res.status === 200) {
|
||||
|
||||
Reference in New Issue
Block a user