Inspector2 / Client / create_code_security_integration

create_code_security_integration

Inspector2.Client.create_code_security_integration(**kwargs)

Creates a code security integration with a source code repository provider.

After calling the CreateCodeSecurityIntegration operation, you complete authentication and authorization with your provider. Next you call the UpdateCodeSecurityIntegration operation to provide the details to complete the integration setup

See also: AWS API Documentation

Request Syntax

response = client.create_code_security_integration(
    details={
        'gitlabSelfManaged': {
            'accessToken': 'string',
            'instanceUrl': 'string'
        }
    },
    name='string',
    tags={
        'string': 'string'
    },
    type='GITLAB_SELF_MANAGED'|'GITHUB'
)
Parameters:
  • details (dict) –

    The integration details specific to the repository provider type.

    Note

    This is a Tagged Union structure. Only one of the following top level keys can be set: gitlabSelfManaged.

    • gitlabSelfManaged (dict) –

      Details specific to creating an integration with a self-managed GitLab instance.

      • accessToken (string) – [REQUIRED]

        The personal access token used to authenticate with the self-managed GitLab instance.

      • instanceUrl (string) – [REQUIRED]

        The URL of the self-managed GitLab instance.

  • name (string) –

    [REQUIRED]

    The name of the code security integration.

  • tags (dict) –

    The tags to apply to the code security integration.

    • (string) –

      • (string) –

  • type (string) –

    [REQUIRED]

    The type of repository provider for the integration.

Return type:

dict

Returns:

Response Syntax

{
    'authorizationUrl': 'string',
    'integrationArn': 'string',
    'status': 'PENDING'|'IN_PROGRESS'|'ACTIVE'|'INACTIVE'|'DISABLING'
}

Response Structure

  • (dict) –

    • authorizationUrl (string) –

      The URL used to authorize the integration with the repository provider.

    • integrationArn (string) –

      The Amazon Resource Name (ARN) of the created code security integration.

    • status (string) –

      The current status of the code security integration.

Exceptions