components:
  parameters:
    applicationId:
      in: path
      name: applicationId
      required: true
      schema:
        $ref: '#/components/schemas/Identifier'
    applicationIdQuery:
      in: query
      name: applicationId
      required: false
      schema:
        type: string
    applicationUserId:
      in: path
      name: applicationUserId
      required: true
      schema:
        $ref: '#/components/schemas/Identifier'
        description: The applicationUserId is the user ID associated with the application.
        type: string
    domainName:
      in: path
      name: domainName
      required: true
      schema:
        $ref: '#/components/schemas/DomainName'
    emailAddress:
      in: query
      name: emailAddress
      required: true
      schema:
        $ref: '#/components/schemas/EmailAddress'
    invitationId:
      in: path
      name: invitationId
      required: true
      schema:
        type: string
    nextToken:
      in: query
      name: nextToken
      required: false
      schema:
        $ref: '#/components/schemas/NextToken'
    policyId:
      in: path
      name: policyId
      required: true
      schema:
        $ref: '#/components/schemas/Identifier'
    teamId:
      in: path
      name: teamId
      required: true
      schema:
        type: string
    tenantId:
      in: path
      name: tenantId
      required: true
      schema:
        type: string
    tokenId:
      in: path
      name: tokenId
      required: true
      schema:
        $ref: '#/components/schemas/Identifier'
    tokenType:
      in: query
      name: type
      schema:
        $ref: '#/components/schemas/TokenType'
  schemas:
    Application:
      properties:
        applicationId:
          readOnly: true
          type: string
        callbackUrls:
          items:
            format: uri
            type: string
          nullable: true
          type: array
        displayName:
          type: string
        effectiveDates:
          properties:
            privacyPolicy:
              format: date-time
              type: string
            termsAndConditions:
              format: date-time
              type: string
          type: object
        logoUrl:
          format: uri
          nullable: true
          type: string
        productId:
          type: string
        resources:
          properties:
            privacyPolicy:
              format: uri
              type: string
            termsAndConditions:
              format: uri
              type: string
          type: object
        status:
          $ref: '#/components/schemas/ApplicationStatus'
        theme:
          $ref: '#/components/schemas/Theme'
        tokenValidity:
          properties:
            accessToken:
              default: 43200
              description: Validity in seconds for the access token
              format: int32
              minimum: 0
              type: number
            idToken:
              default: 43200
              description: Validity in seconds for the id token
              format: int32
              minimum: 0
              type: number
            refreshToken:
              default: 7776000
              description: Validity in seconds for the refresh token
              format: int32
              minimum: 0
              type: number
          type: object
      type: object
    ApplicationStatus:
      enum:
        - ENABLED
        - DISABLED
      readOnly: true
      type: string
    ApplicationUser:
      properties:
        email:
          type: string
        tenantId:
          type: string
        userId:
          type: string
      required:
        - userId
        - tenantId
        - email
      type: object
    AuthCodeGrant:
      properties:
        client_id:
          type: string
        client_secret:
          type: string
        code:
          type: string
        code_verifier:
          type: string
        grant_type:
          enum:
            - authorization_code
          type: string
        redirect_uri:
          type: string
      required:
        - grant_type
        - redirect_uri
        - code
      type: object
    ClientSecret:
      properties:
        secret:
          type: string
        status:
          $ref: '#/components/schemas/ClientSecretStatus'
      required:
        - secret
      type: object
    ClientSecretStatus:
      enum:
        - ENABLED
        - SUSPENDED
      readOnly: true
      type: string
    CreateApplicationRequestSchema:
      allOf:
        - properties:
            displayName:
              type: string
            productId:
              type: string
          required:
            - productId
            - displayName
        - $ref: '#/components/schemas/Application'
    CreateTenantRequestSchema:
      allOf:
        - properties:
            displayName:
              type: string
            productId:
              type: string
          required:
            - displayName
        - $ref: '#/components/schemas/Tenant'
    DomainName:
      description: Domains containing unicode characters must be punycode encoded.
      maxLength: 64
      pattern: ^[a-z0-9-\.]+$
      type: string
    EmailAddress:
      format: email
      type: string
    Identifier:
      maxLength: 88
      pattern: ^[a-zA-Z0-9_-]+$
      type: string
    Identity:
      properties:
        externalId:
          type: string
        tenantId:
          $ref: '#/components/schemas/Identifier'
      type: object
    Location:
      properties:
        city:
          description: Name of the city
          example: Boston
          maxLength: 128
          type: string
        country:
          description: >-
            ISO 3166-1 alpha-2 country code as defined by
            https://en.wikipedia.org/wiki/ISO_3166-1
          example: US
          pattern: '[A-Z]{2}'
          type: string
        latitude:
          example: 42.364
          type: number
        longitude:
          example: -71.0265
          type: number
        metroCode:
          description: Only present in the United States.
          example: '506'
          maxLength: 16
          type: string
        postalCode:
          example: '02128'
          maxLength: 16
          type: string
        subdivision:
          description: Subdivision as defined by https://en.wikipedia.org/wiki/ISO_3166-2
          example: MA
          maxLength: 3
          type: string
        timeZone:
          description: >-
            Time zone, in [IANA time zone database
            format](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones)
          example: America/New_York
          type: string
      type: object
    LoginTenant:
      properties:
        sso:
          properties:
            configurationId:
              type: string
            enabled:
              type: boolean
          required:
            - enabled
            - configurationId
          type: object
        tenantId:
          type: string
      required:
        - tenantId
        - sso
      type: object
    MembershipRole:
      enum:
        - MAINTAINER
        - MEMBER
      type: string
    Namespace:
      default: /
      description: Cannot be changed after the team is created.
      maxLength: 512
      pattern: ^(/|(/[0-9a-zA-Z_-]+)+)$
      type: string
    NextToken:
      maxLength: 4096
      pattern: ^[a-zA-Z0-9_-]+$
      type: string
    Policy:
      properties:
        conditions:
          items:
            $ref: '#/components/schemas/PolicyCondition'
          maxLength: 10
          type: array
        effect:
          $ref: '#/components/schemas/PolicyEffect'
        policyId:
          $ref: '#/components/schemas/Identifier'
      required:
        - effect
      type: object
    PolicyCondition:
      oneOf:
        - $ref: '#/components/schemas/PolicyConditionTenant'
        - $ref: '#/components/schemas/PolicyConditionTeam'
    PolicyConditionTeam:
      properties:
        teamId:
          items:
            $ref: '#/components/schemas/Identifier'
          type: array
        type:
          enum:
            - TEAM
          type: string
      required:
        - type
        - teamId
      type: object
    PolicyConditionTenant:
      properties:
        tenantId:
          items:
            $ref: '#/components/schemas/Identifier'
          type: array
        type:
          enum:
            - TENANT
          type: string
      required:
        - type
        - tenantId
      type: object
    PolicyConditionType:
      enum:
        - TENANT
        - TEAM
      type: string
    PolicyEffect:
      enum:
        - ALLOW
        - DENY
      type: string
    RefreshTokenGrant:
      properties:
        client_id:
          type: string
        client_secret:
          type: string
        grant_type:
          enum:
            - refresh_token
          type: string
        refresh_token:
          type: string
      required:
        - grant_type
        - refresh_token
      type: object
    Tag:
      properties:
        key:
          maxLength: 128
          minLength: 1
          pattern: ^[a-zA-Z0-9_-]+$
          type: string
        value:
          maxLength: 256
          pattern: ^[a-zA-Z0-9_-]+$
          type: string
      required:
        - key
        - value
      type: object
    Tags:
      items:
        $ref: '#/components/schemas/Tag'
      maxItems: 10
      type: array
    Team:
      properties:
        createdDate:
          format: date-time
          type: string
        displayName:
          type: string
        membersCount:
          type: number
        namespace:
          $ref: '#/components/schemas/Namespace'
        status:
          $ref: '#/components/schemas/TeamStatus'
        tags:
          $ref: '#/components/schemas/Tags'
        teamId:
          type: string
        updatedDate:
          format: date-time
          type: string
      required:
        - displayName
      type: object
    TeamInvitation:
      properties:
        email:
          format: email
          type: string
        expirationDate:
          format: date-time
          type: string
        invitationId:
          readOnly: true
          type: string
        role:
          $ref: '#/components/schemas/MembershipRole'
        state:
          $ref: '#/components/schemas/TeamInvitationState'
        tags:
          $ref: '#/components/schemas/Tags'
      required:
        - email
        - role
      type: object
    TeamInvitationState:
      enum:
        - CREATED
        - ACCEPTED
        - EXPIRED
      type: string
    TeamMembership:
      properties:
        email:
          type: string
        memberSince:
          format: date-time
          type: string
        namespace:
          $ref: '#/components/schemas/Namespace'
        role:
          $ref: '#/components/schemas/MembershipRole'
        tags:
          $ref: '#/components/schemas/Tags'
        teamId:
          type: string
        userId:
          type: string
      required:
        - role
        - teamId
      type: object
    TeamStatus:
      enum:
        - ENABLED
        - SUSPENDED
      readOnly: true
      type: string
    Tenant:
      properties:
        administratorTeamId:
          readOnly: true
          type: string
        displayName:
          type: string
        sso:
          properties:
            configurationId:
              type: string
            enabled:
              type: boolean
          required:
            - enabled
          type: object
        status:
          $ref: '#/components/schemas/TenantStatus'
        tenantId:
          readOnly: true
          type: string
      type: object
    TenantDomain:
      properties:
        dnsRecord:
          properties:
            name:
              type: string
            type:
              type: string
            value:
              type: string
          required:
            - name
            - type
            - value
          type: object
        domainName:
          type: string
        status:
          $ref: '#/components/schemas/TenantDomainStatus'
      required:
        - domainName
      type: object
    TenantDomainStatus:
      enum:
        - VERIFIED
        - PENDING
        - FAILED
      type: string
    TenantStatus:
      enum:
        - ENABLED
        - DISABLED
      readOnly: true
      type: string
    Theme:
      nullable: true
      properties:
        background:
          properties:
            color:
              $ref: '#/components/schemas/ThemeColor'
            primaryLayer:
              $ref: '#/components/schemas/ThemeLayer'
            secondaryLayer:
              $ref: '#/components/schemas/ThemeLayer'
          required:
            - color
            - primaryLayer
          type: object
        brand:
          description: Specifies the brand.
          enum:
            - bioreliance
            - mdo
            - millipore
            - milliq
            - supelco
            - safc
            - sigma-aldrich
          type: string
        colors:
          properties:
            primary:
              $ref: '#/components/schemas/ThemeColor'
            secondary:
              $ref: '#/components/schemas/ThemeColor'
          required:
            - primary
            - secondary
          type: object
        parallax:
          description: Enables parallax effect
          type: boolean
        pattern:
          description: >-
            Liquid pattern, see
            https://liquid.emd.design/liquid/components/ld-bg-cells/
          enum:
            - bioreliance
            - f
            - functional
            - hexagon
            - mdo
            - millipore
            - milliq
            - o
            - organic
            - plastic
            - qa-x2f-qc
            - safc
            - sigma-aldrich
            - supelco
            - synthetic
            - t
            - technical
            - tile
          type: string
      required:
        - background
        - colors
        - pattern
        - parallax
      type: object
    ThemeColor:
      description: Liquid colors, see https://liquid.emd.design/liquid/global/colors/
      enum:
        - rb
        - rg
        - rp
        - rr
        - vc
        - vg
        - vm
        - vy
        - sb
        - sy
        - sg
        - sp
      type: string
    ThemeLayer:
      properties:
        color:
          $ref: '#/components/schemas/ThemeColor'
        rotation:
          format: int32
          maximum: 360
          minimum: 0
          type: number
        size:
          format: int32
          maximum: 800
          minimum: 100
          type: number
        x:
          format: int32
          type: number
        'y':
          format: int32
          type: number
      required:
        - color
        - size
        - rotation
        - x
        - 'y'
      type: object
    Token:
      properties:
        accessTokensCreated:
          type: number
        displayName:
          type: string
        expirationDate:
          format: date-time
          type: string
        lastUsedDate:
          format: date-time
          type: string
        rate:
          description: Rate limit in requests per second
          type: number
        status:
          $ref: '#/components/schemas/TokenStatus'
        throttled:
          type: boolean
        token:
          type: string
        tokenId:
          type: string
        type:
          $ref: '#/components/schemas/TokenType'
      required:
        - tokenId
        - type
      type: object
    TokenStatus:
      enum:
        - ENABLED
        - DISABLED
      type: string
    TokenType:
      enum:
        - APPLICATION
        - PERSONAL
      type: string
  securitySchemes:
    Admin:
      openIdConnectUrl: https://login.emddigital.com/
      type: openIdConnect
    CognitoIdp:
      openIdConnectUrl: >-
        https://cognito-idp.us-east-2.amazonaws.com/${UserPool}/.well-known/openid-configuration
      type: openIdConnect
    IdentityConsumers:
      openIdConnectUrl: https://login.emddigital.com/
      type: openIdConnect
    Metering:
      openIdConnectUrl: https://login.emddigital.com/
      type: openIdConnect
    Portal:
      openIdConnectUrl: https://login.emddigital.com/
      type: openIdConnect
    User:
      in: header
      name: Authorization
      type: apiKey
info:
  description: ''
  title: Identity API
  version: 1.0.0
openapi: 3.0.3
paths:
  /.well-known/jwks.json:
    get:
      operationId: DescribeJwks
      responses:
        '200':
          description: Success
    servers:
      - url: https://login.emddigital.com/
  /.well-known/openid-configuration:
    get:
      operationId: DescribeOpenIdConfiguration
      responses:
        '200':
          description: Success
    servers:
      - url: https://login.emddigital.com/
  /applications:
    get:
      operationId: ListApplications
      parameters:
        - $ref: '#/components/parameters/nextToken'
        - in: query
          name: productId
          required: true
          schema:
            $ref: '#/components/schemas/Identifier'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/Application'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - Admin: []
    post:
      operationId: CreateApplication
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateApplicationRequestSchema'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                properties:
                  applicationId:
                    type: string
                required:
                  - applicationId
                type: object
          description: Crated
      security:
        - Admin: []
  /applications/{applicationId}:
    delete:
      operationId: DeleteApplication
      responses:
        '200':
          description: OK
      security:
        - Admin: []
    get:
      operationId: DescribeApplication
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Application'
          description: Success
      security:
        - PortalAndAdmin: []
    parameters:
      - $ref: '#/components/parameters/applicationId'
    put:
      operationId: UpdateApplication
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Application'
        required: true
      responses:
        '200':
          description: OK
      security:
        - Admin: []
  /applications/{applicationId}/policies:
    get:
      operationId: ListApplicationPolicies
      parameters:
        - $ref: '#/components/parameters/nextToken'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/Policy'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - Admin: []
    parameters:
      - $ref: '#/components/parameters/applicationId'
    post:
      operationId: CreateApplicationPolicy
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Policy'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                properties:
                  policyId:
                    $ref: '#/components/schemas/Identifier'
                required:
                  - policyId
                type: object
          description: Success
      security:
        - Admin: []
  /applications/{applicationId}/policies/{policyId}:
    delete:
      operationId: DeleteApplicationPolicy
      responses:
        '200':
          description: Success
      security:
        - Admin: []
    parameters:
      - $ref: '#/components/parameters/applicationId'
      - $ref: '#/components/parameters/policyId'
  /applications/{applicationId}/secrets:
    get:
      operationId: ListApplicationClientSecrets
      parameters:
        - $ref: '#/components/parameters/nextToken'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/ClientSecret'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - Admin: []
    parameters:
      - $ref: '#/components/parameters/applicationId'
    post:
      operationId: CreateApplicationClientSecret
      responses:
        '201':
          content:
            application/json:
              schema:
                properties:
                  secret:
                    type: string
                required:
                  - secret
                type: object
          description: Success
      security:
        - Admin: []
  /applications/{applicationId}/tokens:
    get:
      operationId: ListApplicationTokens
      parameters:
        - $ref: '#/components/parameters/nextToken'
        - $ref: '#/components/parameters/tokenType'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/Token'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - Admin: []
    parameters:
      - $ref: '#/components/parameters/applicationId'
    post:
      operationId: CreateApplicationToken
      requestBody:
        content:
          application/json:
            schema:
              properties:
                displayName:
                  description: Short description of the token
                  maxLength: 32
                  type: string
                lifetime:
                  default: 158112000
                  description: >-
                    Expiration in seconds from today. The default is 158,112,000
                    (5 years).
                  maximum: 158112000
                  minimum: 0
                  type: number
                rate:
                  default: 10
                  description: Requests per second allowed for this token.
                  maximum: 10
                  minimum: 10
                  type: number
                type:
                  $ref: '#/components/schemas/TokenType'
              type: object
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Token'
          description: Created
      security:
        - Admin: []
  /applications/{applicationId}/tokens/{tokenId}:
    delete:
      operationId: DeleteApplicationToken
      responses:
        '200':
          description: OK
      security:
        - Admin: []
    parameters:
      - $ref: '#/components/parameters/applicationId'
      - $ref: '#/components/parameters/tokenId'
    put:
      operationId: UpdateApplicationToken
      requestBody:
        content:
          application/json:
            schema:
              properties:
                status:
                  $ref: '#/components/schemas/TokenStatus'
              type: object
        required: true
      responses:
        '200':
          description: Created
      security:
        - Admin: []
  /applications/{applicationId}/users:
    parameters:
      - $ref: '#/components/parameters/applicationId'
  /applications/{applicationId}/users/{applicationUserId}:
    get:
      description: >
        Look up the userId for a user identified by an application ID and
        application user ID.


        This is required by a few privileged services such as the Metering
        service to map a

        user ID from an application to the user ID used by the Metering service.
        This is a

        sensitive API and access should be granted only to core services of the
        platform.
      operationId: DescribeApplicationUser
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApplicationUser'
          description: Success
        '404':
          content:
            application/json:
              schema:
                type: object
          description: Not found
      security:
        - IdentityConsumers: []
    parameters:
      - $ref: '#/components/parameters/applicationId'
      - $ref: '#/components/parameters/applicationUserId'
  /applications/{applicationId}/users/{applicationUserId}/memberships:
    parameters:
      - $ref: '#/components/parameters/applicationId'
      - $ref: '#/components/parameters/applicationUserId'
  /oauth2/client/{applicationId}:
    get:
      operationId: DescribeClient
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Application'
          description: Success
    parameters:
      - $ref: '#/components/parameters/applicationId'
    servers:
      - url: https://login.emddigital.com/
  /oauth2/code:
    post:
      operationId: CreateAuthorizationCode
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              properties:
                client_id:
                  type: string
                code_challenge:
                  maxLength: 256
                  type: string
                code_challenge_method:
                  enum:
                    - S256
                  type: string
                consent:
                  default: false
                  type: string
                nonce:
                  maxLength: 64
                  type: string
                redirect_uri:
                  format: uri
                  type: string
                response_type:
                  enum:
                    - code
                  type: string
                scope:
                  enum:
                    - openid email
                    - openid
                    - email openid
                  type: string
                state:
                  maxLength: 8192
                  type: string
              required:
                - client_id
                - response_type
                - scope
                - redirect_uri
              type: object
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  code:
                    type: string
                  state:
                    type: string
                required:
                  - code
                type: object
          description: Success
      security:
        - CognitoIdp:
            - aws.cognito.signin.user.admin
    servers:
      - url: https://login.emddigital.com/
  /oauth2/tenant:
    get:
      operationId: ListLoginTenants
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/LoginTenant'
                    type: array
                required:
                  - items
                type: object
          description: Success
    parameters:
      - in: query
        name: domain
        required: true
        schema:
          type: string
    servers:
      - url: https://login.emddigital.com/
  /oauth2/token:
    post:
      operationId: CreateToken
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              oneOf:
                - $ref: '#/components/schemas/AuthCodeGrant'
                - $ref: '#/components/schemas/RefreshTokenGrant'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  access_token:
                    type: string
                  expires_in:
                    maximum: 3600
                    minimum: 0
                    type: number
                  id_token:
                    type: string
                  refresh_token:
                    type: string
                  token_type:
                    enum:
                      - Bearer
                    type: string
                required:
                  - access_token
                  - token_type
                  - expires_in
                type: object
          description: Success
    servers:
      - url: https://login.emddigital.com/
  /oauth2/userinfo:
    get:
      description: >
        The `location` property is an approximation of the user's location,
        derived from requestor's IP address. If the request is made by a
        backend, then the location will be derived from the public IP address of
        the server.

        If the location could not be derived then response will not include the
        `location` property.
      operationId: DescribeUser
      parameters:
        - in: query
          name: location
          schema:
            enum:
              - ip
            type: string
        - description: experimental, may change in the future
          in: query
          name: identities
          schema:
            enum:
              - 'true'
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  email:
                    format: email
                    type: string
                  identities:
                    items:
                      $ref: '#/components/schemas/Identity'
                    type: array
                  location:
                    $ref: '#/components/schemas/Location'
                  sub:
                    format: uuid
                    type: string
                required:
                  - sub
                  - email
                type: object
          description: Success
      security:
        - User: []
    post:
      description: >
        The `location` property is an approximation of the user's location,
        derived from requestor's IP address. If the request is made by a
        backend, then the location will be derived from the public IP address of
        the server.

        If the location could not be derived then response will not include the
        `location` property.
      operationId: DescribeUserPost
      parameters:
        - in: query
          name: location
          schema:
            enum:
              - ip
            type: string
        - description: experimental, may change in the future
          in: query
          name: identities
          schema:
            enum:
              - 'true'
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  email:
                    format: email
                    type: string
                  identities:
                    items:
                      $ref: '#/components/schemas/Identity'
                    type: array
                  location:
                    $ref: '#/components/schemas/Location'
                  sub:
                    format: uuid
                    type: string
                required:
                  - sub
                  - email
                type: object
          description: Success
      security:
        - User: []
    servers:
      - url: https://login.emddigital.com/
  /teams:
    post:
      operationId: CreateTeam
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Team'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                properties:
                  teamId:
                    type: string
                required:
                  - teamId
                type: object
          description: Created
      security:
        - User: []
  /teams/{teamId}:
    get:
      operationId: DescribeTeam
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Team'
          description: Success
      security:
        - User: []
    parameters:
      - $ref: '#/components/parameters/teamId'
  /teams/{teamId}/invitations:
    get:
      operationId: ListTeamInvitations
      parameters:
        - $ref: '#/components/parameters/nextToken'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/TeamInvitation'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - User: []
    parameters:
      - $ref: '#/components/parameters/teamId'
    post:
      operationId: CreateTeamInvitation
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TeamInvitation'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                properties:
                  invitationId:
                    type: string
                required:
                  - invitationId
                type: object
          description: Success
      security:
        - User: []
  /teams/{teamId}/invitations/{invitationId}:
    delete:
      operationId: RemoveTeamInvitation
      responses:
        '200':
          description: Success
      security:
        - User: []
    get:
      operationId: DescribeTeamInvitation
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TeamInvitation'
          description: Success
      security:
        - User: []
    parameters:
      - $ref: '#/components/parameters/teamId'
      - $ref: '#/components/parameters/invitationId'
      - $ref: '#/components/parameters/applicationIdQuery'
    put:
      operationId: AcceptTeamInvitation
      responses:
        '200':
          description: Success
      security:
        - User: []
  /teams/{teamId}/members:
    get:
      operationId: ListTeamMembers
      parameters:
        - $ref: '#/components/parameters/nextToken'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/TeamMembership'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - User: []
    parameters:
      - $ref: '#/components/parameters/teamId'
  /teams/{teamId}/memberships/{applicationUserId}:
    delete:
      operationId: RemoveTeamMembership
      responses:
        '200':
          description: Success
      security:
        - User: []
    get:
      operationId: DescribeTeamMembership
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TeamMembership'
          description: Success
        '404':
          description: Not found
      security:
        - User: []
    parameters:
      - $ref: '#/components/parameters/teamId'
      - $ref: '#/components/parameters/applicationUserId'
    post:
      operationId: CreateTeamMembership
      requestBody:
        content:
          application/json:
            schema:
              properties:
                namespace:
                  $ref: '#/components/schemas/Namespace'
                role:
                  $ref: '#/components/schemas/MembershipRole'
                tags:
                  $ref: '#/components/schemas/Tags'
              required:
                - role
              type: object
        required: true
      responses:
        '201':
          description: Success
      security:
        - User: []
    put:
      operationId: UpdateTeamMembership
      requestBody:
        content:
          application/json:
            schema:
              properties:
                role:
                  $ref: '#/components/schemas/MembershipRole'
                tags:
                  $ref: '#/components/schemas/Tags'
              required:
                - role
              type: object
        required: true
      responses:
        '200':
          description: Success
      security:
        - User: []
  /tenants:
    get:
      operationId: ListTenants
      parameters:
        - $ref: '#/components/parameters/nextToken'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/Tenant'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - Admin: []
    post:
      operationId: CreateTenant
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateTenantRequestSchema'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                properties:
                  tenantId:
                    type: string
                required:
                  - tenantId
                type: object
          description: Crated
      security:
        - Admin: []
  /tenants/{tenantId}:
    delete:
      operationId: DeleteTenant
      responses:
        '200':
          description: OK
      security:
        - Admin: []
    get:
      operationId: DescribeTenant
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Tenant'
          description: Success
      security:
        - Admin: []
    parameters:
      - $ref: '#/components/parameters/tenantId'
    post:
      operationId: UpdateTenant
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Tenant'
        required: true
      responses:
        '200':
          description: OK
      security:
        - Admin: []
  /tenants/{tenantId}/domains:
    get:
      operationId: ListTenantDomains
      parameters:
        - $ref: '#/components/parameters/nextToken'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  items:
                    items:
                      $ref: '#/components/schemas/TenantDomain'
                    type: array
                  nextToken:
                    $ref: '#/components/schemas/NextToken'
                required:
                  - items
                type: object
          description: Success
      security:
        - Admin: []
    parameters:
      - $ref: '#/components/parameters/tenantId'
    post:
      operationId: CreateTenantDomain
      requestBody:
        content:
          application/json:
            schema:
              properties:
                domainName:
                  $ref: '#/components/schemas/DomainName'
              required:
                - domainName
              type: object
      responses:
        '201':
          description: Success
      security:
        - Admin: []
servers:
  - url: https://identity.emddigital.com/v1/
