diff --git a/docs/api-reference/overview/examples/integration.mdx b/docs/api-reference/overview/examples/integration.mdx new file mode 100644 index 000000000..e8da5ea49 --- /dev/null +++ b/docs/api-reference/overview/examples/integration.mdx @@ -0,0 +1,90 @@ +--- +title: "Configure native integrations programmatically" +description: "How to use Infisical API to sync secrets to external secret managers" +--- + +The Infisical API allows you to create programmatic integrations that connect with third-party secret managers to synchronize secrets from Infisical. + +This guide will primarily demonstrate the process using AWS Secret Store Manager (AWS SSM), but the steps are generally applicable to other secret management integrations. + + + For details on setting up AWS SSM synchronization and understanding its prerequisites, refer to the [AWS SSM integration setup documentation](../../../integrations/cloud/aws-secret-manager). + + + + + Authentication is required for all integrations. Use the [Integration Auth API](../../endpoints/integrations/create-auth) with the following parameters to authenticate. + + + Set this parameter to **aws-secret-manager**. + + + The Infisical project ID for the integration. + + + The AWS IAM User Access ID. + + + The AWS IAM User Access Secret Key. + + + ```bash Request + curl --request POST \ + --url https://app.infisical.com/api/v1/integration-auth/access-token \ + --header 'Authorization: ' \ + --header 'Content-Type: application/json' \ + --data '{ + "workspaceId": "", + "integration": "aws-secret-manager", + "accessId": "", + "accessToken": "" + }' + ``` + + + + Once authentication between AWS SSM and Infisical is established, you can configure the synchronization behavior. + This involves specifying the source (environment and secret path in Infisical) and the destination in SSM to which the secrets will be synchronized. + + Use the [integration API](../../endpoints/integrations/create) with the following parameters to configure the sync source and destination. + + + The ID of the integration authentication object used with AWS, obtained from the previous API response. + + + Indicates whether the integration should be active or inactive. + + + The secret name for saving in AWS SSM, which can be arbitrarily chosen. + + + The AWS region where the SSM is located, e.g., `us-east-1`. + + + The Infisical environment slug from which secrets will be synchronized, e.g., `dev`. + + + The Infisical folder path from which secrets will be synchronized, e.g., `/some/path`. The root path is `/`. + + + ```bash Request + curl --request POST \ + --url https://app.infisical.com/api/v1/integration \ + --header 'Authorization: ' \ + --header 'Content-Type: application/json' \ + --data '{ + "integrationAuthId": "", + "sourceEnvironment": "", + "secretPath": "", + "app": "", + "region": "" + }' + ``` + + + + + +Congratulations! You have successfully set up an integration to synchronize secrets from Infisical with AWS SSM. +For more information, [view the integration API reference](../../endpoints/integrations). + \ No newline at end of file diff --git a/docs/mint.json b/docs/mint.json index ebd4fca0b..4b4036585 100644 --- a/docs/mint.json +++ b/docs/mint.json @@ -389,7 +389,8 @@ "pages": [ "api-reference/overview/examples/note", "api-reference/overview/examples/e2ee-disabled", - "api-reference/overview/examples/e2ee-enabled" + "api-reference/overview/examples/e2ee-enabled", + "api-reference/overview/examples/integration" ] } ]