Amazon Q Q Aiguardrails API

The Q Aiguardrails API from Amazon Q — 2 operation(s) for q aiguardrails.

GitHub OpenAPI

Operations 5

POST /assistants/{assistantId}/aiguardrails Create AIGuardrail #
GET /assistants/{assistantId}/aiguardrails List AIGuardrails #
GET /assistants/{assistantId}/aiguardrails/{aiGuardrailId} Get AIGuardrail #
POST /assistants/{assistantId}/aiguardrails/{aiGuardrailId} Update AIGuardrail #
DELETE /assistants/{assistantId}/aiguardrails/{aiGuardrailId} Delete AIGuardrail #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/amazon-q:amazon-q-aiguardrails-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

amazon-q-aiguardrails-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: QBusiness Aiguardrails API
  version: '2023-11-27'
  description: Generated from AWS's published Smithy model for QBusiness. 5 operation(s).
  contact:
    name: Amazon Web Services
    url: https://aws.amazon.com/contact-us/
  license:
    name: Apache 2.0
    identifier: Apache-2.0
    url: https://github.com/aws/api-models-aws/blob/main/LICENSE
servers:
- url: https://wisdom.{region}.amazonaws.com
  variables:
    region:
      default: us-east-1
security:
- sigv4: []
paths:
  /assistants/{assistantId}/aiguardrails:
    post:
      operationId: CreateAIGuardrail
      summary: Create AIGuardrail
      description: Creates an Amazon Q in Connect AI Guardrail.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateAIGuardrailResponse'
        '403':
          description: AccessDeniedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomAccessDeniedException'
        '409':
          description: ConflictException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomConflictException'
        '404':
          description: ResourceNotFoundException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomResourceNotFoundException'
        '402':
          description: ServiceQuotaExceededException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomServiceQuotaExceededException'
        '400':
          description: ThrottlingException; ValidationException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomThrottlingException'
        '401':
          description: UnauthorizedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomUnauthorizedException'
      parameters:
      - name: assistantId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain
          the ARN.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                clientToken:
                  type: string
                  description: A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
                    If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency,
                    see Making retries safe with idempotent APIs..
                name:
                  type: string
                  description: The name of the AI Guardrail.
                blockedInputMessaging:
                  type: string
                  description: The message to return when the AI Guardrail blocks a prompt.
                blockedOutputsMessaging:
                  type: string
                  description: The message to return when the AI Guardrail blocks a model response.
                visibilityStatus:
                  type: string
                  description: The visibility status of the AI Guardrail.
                description:
                  type: string
                  description: A description of the AI Guardrail.
                topicPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailTopicPolicyConfig'
                contentPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailContentPolicyConfig'
                wordPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailWordPolicyConfig'
                sensitiveInformationPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailSensitiveInformationPolicyConfig'
                contextualGroundingPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailContextualGroundingPolicyConfig'
                tags:
                  type: object
                  additionalProperties:
                    type: string
                  description: The tags used to organize, track, or control access for this resource.
              required:
              - name
              - blockedInputMessaging
              - blockedOutputsMessaging
              - visibilityStatus
      tags:
      - Aiguardrails
    get:
      operationId: ListAIGuardrails
      summary: List AIGuardrails
      description: Lists the AI Guardrails available on the Amazon Q in Connect assistant.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListAIGuardrailsResponse'
        '403':
          description: AccessDeniedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomAccessDeniedException'
        '404':
          description: ResourceNotFoundException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomResourceNotFoundException'
        '400':
          description: ThrottlingException; ValidationException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomThrottlingException'
        '401':
          description: UnauthorizedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomUnauthorizedException'
      parameters:
      - name: assistantId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain
          the ARN.
      - name: nextToken
        in: query
        schema:
          type: string
        description: The token for the next set of results. Use the value returned in the previous response in the next request
          to retrieve the next set of results.
      - name: maxResults
        in: query
        schema:
          type: integer
        description: The maximum number of results to return per page.
      tags:
      - Aiguardrails
  /assistants/{assistantId}/aiguardrails/{aiGuardrailId}:
    get:
      operationId: GetAIGuardrail
      summary: Get AIGuardrail
      description: Gets the Amazon Q in Connect AI Guardrail.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetAIGuardrailResponse'
        '403':
          description: AccessDeniedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomAccessDeniedException'
        '404':
          description: ResourceNotFoundException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomResourceNotFoundException'
        '400':
          description: ThrottlingException; ValidationException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomThrottlingException'
        '401':
          description: UnauthorizedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomUnauthorizedException'
      parameters:
      - name: assistantId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain
          the ARN.
      - name: aiGuardrailId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect AI Guardrail.
      tags:
      - Aiguardrails
    post:
      operationId: UpdateAIGuardrail
      summary: Update AIGuardrail
      description: Updates an AI Guardrail.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UpdateAIGuardrailResponse'
        '403':
          description: AccessDeniedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomAccessDeniedException'
        '409':
          description: ConflictException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomConflictException'
        '404':
          description: ResourceNotFoundException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomResourceNotFoundException'
        '400':
          description: ThrottlingException; ValidationException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomThrottlingException'
        '401':
          description: UnauthorizedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomUnauthorizedException'
      parameters:
      - name: assistantId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain
          the ARN.
      - name: aiGuardrailId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect AI Guardrail.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                clientToken:
                  type: string
                  description: A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
                    If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency,
                    see Making retries safe with idempotent APIs..
                visibilityStatus:
                  type: string
                  description: The visibility status of the Amazon Q in Connect AI Guardrail.
                blockedInputMessaging:
                  type: string
                  description: The message to return when the AI Guardrail blocks a prompt.
                blockedOutputsMessaging:
                  type: string
                  description: The message to return when the AI Guardrail blocks a model response.
                description:
                  type: string
                  description: A description of the AI Guardrail.
                topicPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailTopicPolicyConfig'
                contentPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailContentPolicyConfig'
                wordPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailWordPolicyConfig'
                sensitiveInformationPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailSensitiveInformationPolicyConfig'
                contextualGroundingPolicyConfig:
                  $ref: '#/components/schemas/AIGuardrailContextualGroundingPolicyConfig'
              required:
              - visibilityStatus
              - blockedInputMessaging
              - blockedOutputsMessaging
      tags:
      - Aiguardrails
    delete:
      operationId: DeleteAIGuardrail
      summary: Delete AIGuardrail
      description: Deletes an Amazon Q in Connect AI Guardrail.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeleteAIGuardrailResponse'
        '403':
          description: AccessDeniedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomAccessDeniedException'
        '409':
          description: ConflictException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomConflictException'
        '404':
          description: ResourceNotFoundException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomResourceNotFoundException'
        '400':
          description: ThrottlingException; ValidationException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomThrottlingException'
        '401':
          description: UnauthorizedException
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WisdomUnauthorizedException'
      parameters:
      - name: assistantId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain
          the ARN.
      - name: aiGuardrailId
        in: path
        required: true
        schema:
          type: string
        description: The identifier of the Amazon Q in Connect AI Guardrail. Can be either the ID or the ARN. URLs cannot
          contain the ARN.
      tags:
      - Aiguardrails
components:
  securitySchemes:
    sigv4:
      type: apiKey
      in: header
      name: Authorization
      description: AWS Signature Version 4. The Authorization header carries an AWS4-HMAC-SHA256 signature over the canonical
        request, with X-Amz-Date (and X-Amz-Security-Token for temporary credentials). Not a bearer token.
      x-aws-sigv4:
        signingName: wisdom
  schemas:
    AIGuardrailContentPolicyConfig:
      type: object
      properties:
        filtersConfig:
          type: array
          items:
            $ref: '#/components/schemas/GuardrailContentFilterConfig'
          description: Contains the type of the content filter and how strongly it should apply to prompts and model responses.
      required:
      - filtersConfig
    AIGuardrailContextualGroundingPolicyConfig:
      type: object
      properties:
        filtersConfig:
          type: array
          items:
            $ref: '#/components/schemas/GuardrailContextualGroundingFilterConfig'
          description: The filter configuration details for the AI Guardrails contextual grounding policy.
      required:
      - filtersConfig
    AIGuardrailData:
      type: object
      properties:
        assistantId:
          type: string
          description: The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain
            the ARN.
        assistantArn:
          type: string
          description: The Amazon Resource Name (ARN) of the Amazon Q in Connect assistant.
        aiGuardrailArn:
          type: string
          description: The Amazon Resource Name (ARN) of the AI Guardrail.
        aiGuardrailId:
          type: string
          description: The identifier of the Amazon Q in Connect AI Guardrail.
        name:
          type: string
          description: The name of the AI Guardrail.
        visibilityStatus:
          type: string
          description: The visibility status of the AI Guardrail.
        blockedInputMessaging:
          type: string
          description: The message to return when the AI Guardrail blocks a prompt.
        blockedOutputsMessaging:
          type: string
          description: The message to return when the AI Guardrail blocks a model response.
        description:
          type: string
          description: A description of the AI Guardrail.
        topicPolicyConfig:
          $ref: '#/components/schemas/AIGuardrailTopicPolicyConfig'
        contentPolicyConfig:
          $ref: '#/components/schemas/AIGuardrailContentPolicyConfig'
        wordPolicyConfig:
          $ref: '#/components/schemas/AIGuardrailWordPolicyConfig'
        sensitiveInformationPolicyConfig:
          $ref: '#/components/schemas/AIGuardrailSensitiveInformationPolicyConfig'
        contextualGroundingPolicyConfig:
          $ref: '#/components/schemas/AIGuardrailContextualGroundingPolicyConfig'
        tags:
          type: object
          additionalProperties:
            type: string
          description: The tags used to organize, track, or control access for this resource.
        status:
          type: string
          description: The status of the AI Guardrail.
        modifiedTime:
          type: string
          description: The time the AI Guardrail was last modified.
        lastModifiedTime:
          type: string
          description: The timestamp when the AI Guardrail was last modified.
        lastModifiedRegion:
          type: string
          description: The Amazon Web Services Region where the AI Guardrail was last modified.
      required:
      - assistantId
      - assistantArn
      - aiGuardrailArn
      - aiGuardrailId
      - name
      - visibilityStatus
      - blockedInputMessaging
      - blockedOutputsMessaging
    AIGuardrailSensitiveInformationPolicyConfig:
      type: object
      properties:
        piiEntitiesConfig:
          type: array
          items:
            $ref: '#/components/schemas/GuardrailPiiEntityConfig'
          description: A list of PII entities to configure to the AI Guardrail.
        regexesConfig:
          type: array
          items:
            $ref: '#/components/schemas/GuardrailRegexConfig'
          description: A list of regular expressions to configure to the AI Guardrail.
    AIGuardrailSummary:
      type: object
      properties:
        name:
          type: string
          description: The name of the AI Guardrail.
        assistantId:
          type: string
          description: The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain
            the ARN.
        assistantArn:
          type: string
          description: The Amazon Resource Name (ARN) of the Amazon Q in Connect assistant.
        aiGuardrailId:
          type: string
          description: The identifier of the Amazon Q in Connect AI Guardrail.
        aiGuardrailArn:
          type: string
          description: The Amazon Resource Name (ARN) of the AI Guardrail.
        modifiedTime:
          type: string
          description: The time the AI Guardrail was last modified.
        lastModifiedTime:
          type: string
          description: The timestamp when the AI Guardrail was last modified.
        lastModifiedRegion:
          type: string
          description: The Amazon Web Services Region where the AI Guardrail was last modified.
        visibilityStatus:
          type: string
          description: The visibility status of the AI Guardrail.
        description:
          type: string
          description: A description of the AI Guardrail.
        status:
          type: string
          description: The status of the AI Guardrail.
        tags:
          type: object
          additionalProperties:
            type: string
          description: The tags used to organize, track, or control access for this resource.
      required:
      - name
      - assistantId
      - assistantArn
      - aiGuardrailId
      - aiGuardrailArn
      - visibilityStatus
    AIGuardrailTopicPolicyConfig:
      type: object
      properties:
        topicsConfig:
          type: array
          items:
            $ref: '#/components/schemas/GuardrailTopicConfig'
          description: A list of policies related to topics that the AI Guardrail should deny.
      required:
      - topicsConfig
    AIGuardrailWordPolicyConfig:
      type: object
      properties:
        wordsConfig:
          type: array
          items:
            $ref: '#/components/schemas/GuardrailWordConfig'
          description: A list of words to configure for the AI Guardrail.
        managedWordListsConfig:
          type: array
          items:
            $ref: '#/components/schemas/GuardrailManagedWordsConfig'
          description: A list of managed words to configure for the AI Guardrail.
    CreateAIGuardrailResponse:
      type: object
      properties:
        aiGuardrail:
          $ref: '#/components/schemas/AIGuardrailData'
    DeleteAIGuardrailResponse:
      type: object
      properties: {}
    GetAIGuardrailResponse:
      type: object
      properties:
        aiGuardrail:
          $ref: '#/components/schemas/AIGuardrailData'
        versionNumber:
          type: integer
          description: The version number of the AI Guardrail version (returned if an AI Guardrail version was specified via
            use of a qualifier for the aiGuardrailId on the request).
    GuardrailContentFilterConfig:
      type: object
      properties:
        type:
          type: string
          description: The harmful category that the content filter is applied to.
        inputStrength:
          type: string
          description: The strength of the content filter to apply to prompts. As you increase the filter strength, the likelihood
            of filtering harmful content increases and the probability of seeing harmful content in your application reduces.
        outputStrength:
          type: string
          description: The strength of the content filter to apply to model responses. As you increase the filter strength,
            the likelihood of filtering harmful content increases and the probability of seeing harmful content in your application
            reduces.
      required:
      - type
      - inputStrength
      - outputStrength
    GuardrailContextualGroundingFilterConfig:
      type: object
      properties:
        type:
          type: string
          description: The filter type for the AI Guardrail's contextual grounding filter.
        threshold:
          type: number
          description: The threshold details for the AI Guardrail's contextual grounding filter.
      required:
      - type
      - threshold
    GuardrailManagedWordsConfig:
      type: object
      properties:
        type:
          type: string
          description: The managed word type to configure for the AI Guardrail.
      required:
      - type
    GuardrailPiiEntityConfig:
      type: object
      properties:
        type:
          type: string
          description: 'Configure AI Guardrail type when the PII entity is detected. The following PIIs are used to block
            or mask sensitive information: General ADDRESS A physical address, such as "100 Main Street, Anytown, USA" or
            "Suite #12, Building 123". An address can include information such as the street, building, location, city, state,
            country, county, zip code, precinct, and neighborhood. AGE An individual''s age, including the quantity and unit
            of time. For example, in the phrase "I am 40 years old," Guarrails recognizes "40 years" as an age. NAME An individual''s
            name. This entity type does not include titl'
        action:
          type: string
          description: Configure AI Guardrail's action when the PII entity is detected.
      required:
      - type
      - action
    GuardrailRegexConfig:
      type: object
      properties:
        name:
          type: string
          description: The name of the regular expression to configure for the AI Guardrail.
        description:
          type: string
          description: The description of the regular expression to configure for the AI Guardrail.
        pattern:
          type: string
          description: The regular expression pattern to configure for the AI Guardrail.
        action:
          type: string
          description: The AI Guardrail action to configure when matching regular expression is detected.
      required:
      - name
      - pattern
      - action
    GuardrailTopicConfig:
      type: object
      properties:
        name:
          type: string
          description: The name of the topic to deny.
        definition:
          type: string
          description: A definition of the topic to deny.
        examples:
          type: array
          items:
            type: string
          description: A list of prompts, each of which is an example of a prompt that can be categorized as belonging to
            the topic.
        type:
          type: string
          description: Specifies to deny the topic.
      required:
      - name
      - definition
      - type
    GuardrailWordConfig:
      type: object
      properties:
        text:
          type: string
          description: Text of the word configured for the AI Guardrail to block.
      required:
      - text
    ListAIGuardrailsResponse:
      type: object
      properties:
        aiGuardrailSummaries:
          type: array
          items:
            $ref: '#/components/schemas/AIGuardrailSummary'
          description: The summaries of the AI Guardrails.
        nextToken:
          type: string
          description: The token for the next set of results. Use the value returned in the previous response in the next
            request to retrieve the next set of results.
      required:
      - aiGuardrailSummaries
    UpdateAIGuardrailResponse:
      type: object
      properties:
        aiGuardrail:
          $ref: '#/components/schemas/AIGuardrailData'
    WisdomAccessDeniedException:
      type: object
      properties:
        message:
          type: string
    WisdomConflictException:
      type: object
      properties:
        message:
          type: string
    WisdomResourceNotFoundException:
      type: object
      properties:
        message:
          type: string
        resourceName:
          type: string
          description: The specified resource name.
    WisdomServiceQuotaExceededException:
      type: object
      properties:
        message:
          type: string
    WisdomThrottlingException:
      type: object
      properties:
        message:
          type: string
    WisdomUnauthorizedException:
      type: object
      properties:
        message:
          type: string
x-provenance:
  method: harvested
  publisher: Amazon Web Services
  source: https://raw.githubusercontent.com/aws/api-models-aws/3cd98287b471c106254abd89279cc87308d38bfd/models/qconnect/service/2020-10-19/qconnect-2020-10-19.json
  note: converted by smithy-to-openapi.py from AWS's Smithy model (roadmap#1001)