> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bango.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update An Entitlement

> Update an entitlement.



## OpenAPI

````yaml /openapi/current/dvm/reseller-to-dvm/entitlement/openapi.json patch /v1/entitlement
openapi: 3.1.0
info:
  title: Reseller to DVM - Entitlement
  summary: Current / DVM / Reseller to DVM / Entitlement
  description: Create, get, update and cancel entitlements.
  version: 1.0.0
servers: []
security: []
tags:
  - name: Entitlements
    description: API methods to manage entitlements
paths:
  /v1/entitlement:
    patch:
      tags:
        - Entitlements
      summary: Update An Entitlement
      description: Update an entitlement.
      operationId: Update_an_entitlement_v1_entitlement_patch
      parameters:
        - name: X-RequestIdentifier
          in: header
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            description: Optional identifier to support idempotency
            title: X-Requestidentifier
          description: Optional identifier to support idempotency
        - name: X-Request-Id
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              Unique request id generated by the reseller. Useful for e2e
              trouble-shooting. While listed as an optional header, some content
              providers consider this to be mandatory.
            title: X-Request-Id
          description: >-
            Unique request id generated by the reseller. Useful for e2e
            trouble-shooting. While listed as an optional header, some content
            providers consider this to be mandatory.
        - name: X-Operation-Id
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              Reseller-generated unique id per operation. Used by some content
              providers to identify an idempotent retry. While listed as an
              optional header, some content providers consider this to be
              mandatory.
            title: X-Operation-Id
          description: >-
            Reseller-generated unique id per operation. Used by some content
            providers to identify an idempotent retry. While listed as an
            optional header, some content providers consider this to be
            mandatory.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EntitlementUpdate'
            examples:
              Product update:
                value:
                  entitlementId: a212856a-4fd5-490b-a79c-f6dc950c2497
                  productKey: MUSIC_PREMIUM
              Date expiry update:
                value:
                  entitlementId: a212856a-4fd5-490b-a79c-f6dc950c2497
                  dateExpiry: '2024-12-05T07:46:52Z'
              Auto suspend date update:
                value:
                  entitlementId: a212856a-4fd5-490b-a79c-f6dc950c2497
                  dateAutoSuspend: '2024-09-05T07:46:52Z'
              Notification Url update:
                value:
                  entitlementId: a212856a-4fd5-490b-a79c-f6dc950c2497
                  notificationUrl: >-
                    https://www.example2.com/notification/a25100b8-4e0c-4e37-b921-cac9cb1e930f
              Customer Identifier update:
                value:
                  entitlementId: a212856a-4fd5-490b-a79c-f6dc950c2497
                  customerIdentifier: '4407987654321'
              External entitlementId update:
                value:
                  entitlementId: a212856a-4fd5-490b-a79c-f6dc950c2497
                  externalEntitlementId: c843678f-d45a-49f4-868d-2bbc445b2c2e
      responses:
        '200':
          description: Entitlement updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EntitlementRead'
              examples:
                OK:
                  value:
                    entitlementId: a25100b8-4e0c-4e37-b921-cac9cb1e930f
                    customerIdentifier: '4407123456789'
                    sharedCustomerId: 414b3019-0c28-4d14-9c5f-6217b8bd1e3e
                    bangoUserId: '2147483647'
                    productKey: BangoMusic
                    entitlementDisplayName: 30 days Bango music
                    merchantAccountKey: BANGO
                    dateCreated: '2020-06-22T17:35:38.92Z'
                    dateActivated: '2020-06-22T17:36:01Z'
                    dateExpiry: '0001-01-01T00:00:00Z'
                    dateEnded: '0001-01-01T00:00:00Z'
                    dateFailed: '0001-01-01T00:00:00Z'
                    responseCode: OK
                    responseMessage: Success
                    status: ACTIVE
                    externalEntitlementId: 124130d2-2cbc-45a1-ab9b-dfa8b67a2e63
                    extensionData:
                      additionalProp1: string
                      additionalProp2: string
                      additionalProp3: string
                    extraInformation:
                      communicationInformation:
                        emailAddress: 123@abc.co.uk
                        msisdn: '441234567890'
                      clientDevice:
                        type: STB
                        id: bc449c9e-406f-4399-a3ff-8671a27ac410
                        typeId: P49AJFND8NFN23NANGAJG
                        modelName: STB Model X7
                        modelNumber: IAH45IAOF/5
                        serialNumber: JHFJHA43JNFA9393GFD
                        osType: Linux
                        osVersion: 10.3.8
                        macAddress: 4A-0F-99-F2-D3-DD
                        browser: Firefox
                      source:
                        channelType: Website
                        campaignRef: SUMMER_PROMO
                        referrer: SEARCH_ENGINE
                        bundleId: BundleABC123
                        country: United Kingdom
                        region: East Anglia
                        brand: BrandABC
          headers:
            X-Idempotent-Record:
              description: >-
                Set when the request includes an `X-RequestIdentifier` header.
                `CREATED` for the first request with that identifier. `EXISTS`
                for a repeat, when the stored response is returned. `FAILED`
                when the request was processed but its idempotency record could
                not be read or saved, so a retry with the same identifier may be
                processed again.
              schema:
                type: string
                enum:
                  - CREATED
                  - EXISTS
                  - FAILED
        '202':
          description: An action is required to be performed by the client
          content:
            application/json:
              examples:
                ClientActionRequired:
                  value:
                    entitlementId: a25100b8-4e0c-4e37-b921-cac9cb1e930f
                    customerIdentifier: '4407123456789'
                    sharedCustomerId: 414b3019-0c28-4d14-9c5f-6217b8bd1e3e
                    bangoUserId: '2147483647'
                    productKey: BangoMusic
                    entitlementDisplayName: 30 days Bango music
                    merchantAccountKey: BANGO
                    dateCreated: '2020-06-22T17:35:38.92Z'
                    dateActivated: '2020-06-22T17:36:01Z'
                    dateExpiry: '0001-01-01T00:00:00Z'
                    dateEnded: '0001-01-01T00:00:00Z'
                    dateFailed: '0001-01-01T00:00:00Z'
                    responseCode: CLIENT_ACTION_REQUIRED
                    responseMessage: An action is required to be performed by the client.
                    status: ACTIVE
                    externalEntitlementId: 124130d2-2cbc-45a1-ab9b-dfa8b67a2e63
                    extensionData:
                      additionalProp1: string
                      additionalProp2: string
                      additionalProp3: string
                    extraInformation:
                      communicationInformation:
                        emailAddress: 123@abc.co.uk
                        msisdn: '441234567890'
                      clientDevice:
                        type: STB
                        id: bc449c9e-406f-4399-a3ff-8671a27ac410
                        typeId: P49AJFND8NFN23NANGAJG
                        modelName: STB Model X7
                        modelNumber: IAH45IAOF/5
                        serialNumber: JHFJHA43JNFA9393GFD
                        osType: Linux
                        osVersion: 10.3.8
                        macAddress: 4A-0F-99-F2-D3-DD
                        browser: Firefox
                      source:
                        channelType: Website
                        campaignRef: SUMMER_PROMO
                        referrer: SEARCH_ENGINE
                        bundleId: BundleABC123
                        country: United Kingdom
                        region: East Anglia
                        brand: BrandABC
                    parameters:
                      action: NAVIGATE_TO_URL
                      url: >-
                        https://example.com/?entitlementId=a25100b8-4e0c-4e37-b921-cac9cb1e930f
              schema:
                $ref: '#/components/schemas/EntitlementUpdateRead'
          headers:
            X-Idempotent-Record:
              description: >-
                Set when the request includes an `X-RequestIdentifier` header.
                `CREATED` for the first request with that identifier. `EXISTS`
                for a repeat, when the stored response is returned. `FAILED`
                when the request was processed but its idempotency record could
                not be read or saved, so a retry with the same identifier may be
                processed again.
              schema:
                type: string
                enum:
                  - CREATED
                  - EXISTS
                  - FAILED
        '400':
          description: Bad request
          content:
            application/json:
              examples:
                Bad request:
                  value:
                    responseCode: BAD_REQUEST
                    responseMessage: Invalid request.
                    metadata:
                      responseMessageFrom: BANGO
                Operation not supported:
                  value:
                    responseCode: OPERATION_NOT_SUPPORTED
                    responseMessage: Operation not supported for entitlement route.
                    metadata:
                      responseMessageFrom: BANGO
                Maximum entitlements for product:
                  value:
                    responseCode: BAD_REQUEST
                    responseMessage: >-
                      Maximum number of entitlements for the requested product
                      key already reached.
                    metadata:
                      responseMessageFrom: BANGO
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Invalid credentials (no response body returned)
        '403':
          description: No active entitlement route found
          content:
            application/json:
              examples:
                Not available:
                  value:
                    responseCode: NOT_AVAILABLE
                    responseMessage: No active entitlement routes found.
                    metadata:
                      responseMessageFrom: BANGO
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Not found
          content:
            application/json:
              examples:
                Not found:
                  value:
                    responseCode: NOT_FOUND
                    responseMessage: Entitlement Not Found
                    metadata:
                      responseMessageFrom: BANGO
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '409':
          description: >-
            Conflict: the state of the entitlement, or an idempotent request in
            progress
          content:
            application/json:
              examples:
                Invalid state:
                  value:
                    responseCode: INVALID_STATE
                    responseMessage: >-
                      Operation invalid for the current state of the
                      entitlement.
                    metadata:
                      responseMessageFrom: BANGO
                Already exists:
                  value:
                    responseCode: ALREADY_EXISTS
                    responseMessage: Entitlement already exists.
                    metadata:
                      responseMessageFrom: BANGO
                Suspend and update:
                  value:
                    responseCode: CONFLICT
                    responseMessage: >-
                      It is not possible to suspend an entitlement and update it
                      at the same time
                    metadata:
                      responseMessageFrom: BANGO
                Resume and update:
                  value:
                    responseCode: CONFLICT
                    responseMessage: >-
                      It is not possible to resume an entitlement and update it
                      at the same time
                    metadata:
                      responseMessageFrom: BANGO
                Idempotent request in progress:
                  value:
                    responseCode: IDEMPOTENT_REQUEST_IN_PROGRESS
                    responseMessage: Idempotency request in progress. Please try again later.
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          headers:
            X-Idempotent-Record:
              description: >-
                Set to `IN_PROGRESS` when the conflict is caused by an earlier
                request with the same `X-RequestIdentifier` that is still being
                processed.
              schema:
                type: string
                enum:
                  - IN_PROGRESS
        '429':
          description: Too Many Requests
          content:
            application/json:
              examples:
                Too Many Requests:
                  value:
                    responseCode: TOO_MANY_REQUESTS
                    responseMessage: Request limit reached. Please try again later.
                    metadata:
                      responseMessageFrom: BANGO
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              examples:
                Internal server error:
                  value:
                    responseCode: INTERNAL_ERROR
                    metadata:
                      responseMessageFrom: BANGO
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '503':
          description: Service Unavailable
          content:
            application/json:
              examples:
                Service Unavailable:
                  value:
                    responseCode: SERVICE_UNAVAILABLE
                    metadata:
                      responseMessageFrom: BANGO
                Idempotency service unavailable:
                  value:
                    responseCode: SERVICE_UNAVAILABLE
                    responseMessage: >-
                      The server is undergoing maintenance and is not available.
                      Please, try again later.
                    metadata:
                      responseMessageFrom: BANGO
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          headers:
            X-Idempotent-Record:
              description: Set to `FAILED` when the idempotency service is not available.
              schema:
                type: string
                enum:
                  - FAILED
      security:
        - XApiKey: []
        - BasicAuth: []
        - OAuth2: []
components:
  schemas:
    EntitlementUpdate:
      properties:
        entitlementId:
          type: string
          title: Entitlementid
          description: Unique identifier representing a specific entitlement
        customerIdentifier:
          type: string
          maxLength: 400
          title: Customeridentifier
          description: User unique identifier
        productKey:
          type: string
          maxLength: 255
          title: Productkey
          description: Entitlement product unique identifier
        entitlementDisplayName:
          type: string
          title: Entitlementdisplayname
          description: Entitlement display name. For example, "30 days Bango music"
        offerKey:
          type: string
          title: Offerkey
          description: Entitlement offer. For example, "BUNDLE" (optional).
        dateExpiry:
          type: string
          format: date-time
          title: Dateexpiry
          description: >-
            Entitlement expiry date in UTC ISO 8601 format. Null if no expiry
            (yyyy-MM-ddThh:mm:ssZ)
        dateAutoSuspend:
          type: string
          format: date-time
          title: Dateautosuspend
          description: >-
            Entitlement auto-suspension date in UTC ISO 8601 format. Null if no
            auto-suspension
        notificationUrl:
          type: string
          title: Notificationurl
          description: >-
            The (POST) endpoint where all entitlement lifecycle notifications
            will be sent
        externalEntitlementId:
          type: string
          maxLength: 255
          title: Externalentitlementid
          description: >-
            Unique identifier for the entitlement provided by the Reseller. If
            the previous attempt to create an entitlement failed, the
            externalEntitlementId can be reused in a new create request.
        extensionData:
          additionalProperties:
            type: string
            maxLength: 250
          type: object
          title: Extensiondata
          description: Custom key value pairs
        extraInformation:
          $ref: '#/components/schemas/ExtraInformation'
          title: Extrainformation
      type: object
      required:
        - entitlementId
      title: EntitlementUpdate
      description: Entitlement update request.
    EntitlementRead:
      properties:
        entitlementId:
          type: string
          format: uuid
          title: Entitlementid
          description: Unique identifier representing a specific entitlement.
        customerIdentifier:
          type: string
          title: Customeridentifier
          description: Unique, immutable user identifier
        sharedCustomerId:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Sharedcustomerid
          description: >-
            Bango generated id shared between reseller and merchant for this
            customer (contact support for setup)
        bangoUserId:
          type: string
          title: Bangouserid
          description: Bango-generated customer identifier.
        merchantAccountKey:
          type: string
          title: Merchantaccountkey
          description: Unique identifier for the content provider
        productKey:
          type: string
          title: Productkey
          description: Unique identifier for the product/offer
        notificationUrl:
          anyOf:
            - type: string
            - type: 'null'
          title: Notificationurl
          description: >-
            The endpoint where Bango will send all notifications regarding this
            entitlement
        offerKey:
          anyOf:
            - type: string
            - type: 'null'
          title: Offerkey
          description: Entitlement offer identifier
        externalEntitlementId:
          anyOf:
            - type: string
            - type: 'null'
          title: Externalentitlementid
          description: >-
            Unique identifier for the entitlement provided by the reseller. If
            the previous attempt to create an entitlement failed, this value can
            be reused.
        entitlementDisplayName:
          anyOf:
            - type: string
            - type: 'null'
          title: Entitlementdisplayname
          description: Entitlement display name used in reports.
        dateCreated:
          type: string
          format: date-time
          title: Datecreated
          description: Timestamp for the creation of the entitlement
        dateActivated:
          type: string
          format: date-time
          title: Dateactivated
          description: >-
            Timestamp provided by the content provider when the entitlement is
            activated
          default: '0001-01-01T00:00:00Z'
        dateEnded:
          type: string
          format: date-time
          title: Dateended
          description: Timestamp for when the entitlement terminated
          default: '0001-01-01T00:00:00Z'
        dateSuspended:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Datesuspended
          description: Timestamp for when the entitlement was suspended
        dateResumed:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Dateresumed
          description: Timestamp for when the entitlement was last resumed
        dateExpiry:
          type: string
          format: date-time
          title: Dateexpiry
          description: >-
            If set, Bango will schedule a termination request to the content
            provider on this date. Date format must be ISO 8601
          default: '0001-01-01T00:00:00Z'
        dateFailed:
          type: string
          format: date-time
          title: Datefailed
          description: Date when the creation of the entitlement failed
          default: '0001-01-01T00:00:00Z'
        dateAutoSuspend:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Dateautosuspend
          description: >-
            If set, Bango will schedule a suspension request to the content
            provider on this date. Date format must be ISO 8601
        responseCode:
          type: string
          title: Responsecode
          description: Result of entitlement operation. `OK` on success.
          examples:
            - OK
        responseMessage:
          type: string
          title: Responsemessage
          description: >-
            Response message of entitlement operation. `Success` if completed
            successfully.
          examples:
            - Success
        status:
          $ref: '#/components/schemas/EntitlementStatus'
          description: >
            The entitlement status. Possible values are:

            * PENDING: The entitlement has been initiated, but the user has not
            yet completed the activation process.

            * ACTIVE: The entitlement has been successfully activated

            * SUSPENDED: The entitlement has been suspended.

            * ACTIVE-ENDING: The entitlement is ending at the end of the current
            period.

            * CANCELLED: The entitlement has been cancelled.

            * REVOKED: The entitlement has been revoked.

            * FAILED: The entitlement could not be created.
        activationCode:
          anyOf:
            - type: string
            - type: 'null'
          title: Activationcode
          description: Code or token used for the entitlement activation
        extensionData:
          additionalProperties:
            type: string
            maxLength: 250
          type: object
          title: Extensiondata
          description: Custom key value pairs
        extraInformation:
          $ref: '#/components/schemas/ExtraInformation'
          title: Extrainformation
        financeData:
          $ref: '#/components/schemas/FinanceData'
          title: Financedata
          description: Finance Data.
      type: object
      required:
        - entitlementId
        - customerIdentifier
        - bangoUserId
        - merchantAccountKey
        - productKey
        - entitlementDisplayName
        - dateCreated
        - responseCode
        - responseMessage
        - status
      title: EntitlementRead
      description: Entitlement.
    EntitlementUpdateRead:
      properties:
        entitlementId:
          type: string
          format: uuid
          title: Entitlementid
          description: Unique identifier representing a specific entitlement.
        customerIdentifier:
          type: string
          title: Customeridentifier
          description: Unique, immutable user identifier
        sharedCustomerId:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Sharedcustomerid
          description: >-
            Bango generated id shared between reseller and merchant for this
            customer (contact support for setup)
        bangoUserId:
          type: string
          title: Bangouserid
          description: Bango-generated customer identifier.
        merchantAccountKey:
          type: string
          title: Merchantaccountkey
          description: Unique identifier for the content provider
        productKey:
          type: string
          title: Productkey
          description: Unique identifier for the product/offer
        notificationUrl:
          anyOf:
            - type: string
            - type: 'null'
          title: Notificationurl
          description: >-
            The endpoint where Bango will send all notifications regarding this
            entitlement
        offerKey:
          anyOf:
            - type: string
            - type: 'null'
          title: Offerkey
          description: Entitlement offer identifier
        externalEntitlementId:
          anyOf:
            - type: string
            - type: 'null'
          title: Externalentitlementid
          description: >-
            Unique identifier for the entitlement provided by the reseller. If
            the previous attempt to create an entitlement failed, this value can
            be reused.
        entitlementDisplayName:
          anyOf:
            - type: string
            - type: 'null'
          title: Entitlementdisplayname
          description: Entitlement display name used in reports.
        dateCreated:
          type: string
          format: date-time
          title: Datecreated
          description: Timestamp for the creation of the entitlement
        dateActivated:
          type: string
          format: date-time
          title: Dateactivated
          description: >-
            Timestamp provided by the content provider when the entitlement is
            activated
          default: '0001-01-01T00:00:00Z'
        dateEnded:
          type: string
          format: date-time
          title: Dateended
          description: Timestamp for when the entitlement terminated
          default: '0001-01-01T00:00:00Z'
        dateSuspended:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Datesuspended
          description: Timestamp for when the entitlement was suspended
        dateResumed:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Dateresumed
          description: Timestamp for when the entitlement was last resumed
        dateExpiry:
          type: string
          format: date-time
          title: Dateexpiry
          description: >-
            If set, Bango will schedule a termination request to the content
            provider on this date. Date format must be ISO 8601
          default: '0001-01-01T00:00:00Z'
        dateFailed:
          type: string
          format: date-time
          title: Datefailed
          description: Date when the creation of the entitlement failed
          default: '0001-01-01T00:00:00Z'
        dateAutoSuspend:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Dateautosuspend
          description: >-
            If set, Bango will schedule a suspension request to the content
            provider on this date. Date format must be ISO 8601
        responseCode:
          type: string
          title: Responsecode
          description: Result of entitlement operation. `OK` on success.
          examples:
            - OK
        responseMessage:
          type: string
          title: Responsemessage
          description: >-
            Response message of entitlement operation. `Success` if completed
            successfully.
          examples:
            - Success
        status:
          $ref: '#/components/schemas/EntitlementStatus'
          description: >
            The entitlement status. Possible values are:

            * PENDING: The entitlement has been initiated, but the user has not
            yet completed the activation process.

            * ACTIVE: The entitlement has been successfully activated

            * SUSPENDED: The entitlement has been suspended.

            * ACTIVE-ENDING: The entitlement is ending at the end of the current
            period.

            * CANCELLED: The entitlement has been cancelled.

            * REVOKED: The entitlement has been revoked.

            * FAILED: The entitlement could not be created.
        activationCode:
          anyOf:
            - type: string
            - type: 'null'
          title: Activationcode
          description: Code or token used for the entitlement activation
        extensionData:
          additionalProperties:
            type: string
            maxLength: 250
          type: object
          title: Extensiondata
          description: Custom key value pairs
        extraInformation:
          $ref: '#/components/schemas/ExtraInformation'
          title: Extrainformation
        financeData:
          $ref: '#/components/schemas/FinanceData'
          title: Financedata
          description: Finance Data.
        parameters:
          $ref: '#/components/schemas/UpdateParameters'
          title: Parameters
          description: >-
            Information needed for entitlement activation. Present only if
            status is `PENDING`.
      type: object
      required:
        - entitlementId
        - customerIdentifier
        - bangoUserId
        - merchantAccountKey
        - productKey
        - entitlementDisplayName
        - dateCreated
        - responseCode
        - responseMessage
        - status
      title: EntitlementUpdateRead
      description: |-
        Entitlement returned by the update operation.

        The update response returns activation `parameters` in camelCase
        (`action` / `url` / `urlExpiry`). Present only when client action is
        required to complete the update.
    ErrorResponse:
      properties:
        responseCode:
          type: string
          title: Responsecode
          description: >-
            Bango code that identifies the error, for example `BAD_REQUEST`,
            `NOT_AVAILABLE`, `NOT_FOUND`, `INVALID_STATE` or `INTERNAL_ERROR`.
            See the examples on each response for the codes that the operation
            can return.
          examples:
            - BAD_REQUEST
        responseMessage:
          type: string
          title: Responsemessage
          description: Description of the error
        metadata:
          $ref: '#/components/schemas/ErrorMetadata'
          title: Metadata
          description: Error Metadata
      type: object
      required:
        - responseCode
      title: ErrorResponse
      description: Error response for Entitlement API.
    ExtraInformation:
      properties:
        communicationInformation:
          $ref: '#/components/schemas/CommunicationInformation'
          title: Communicationinformation
        clientDevice:
          $ref: '#/components/schemas/ClientDevice'
          title: Clientdevice
          description: Client device information.
        source:
          $ref: '#/components/schemas/Source'
          description: Entitlement creation / activation source.
      type: object
      title: ExtraInformation
      description: Entitlement extra information.
    EntitlementStatus:
      type: string
      enum:
        - PENDING
        - ACTIVE
        - SUSPENDED
        - ACTIVE-ENDING
        - CANCELLED
        - REVOKED
        - FAILED
      title: EntitlementStatus
      description: Entitlement status.
    FinanceData:
      properties:
        source:
          type: string
          title: Source
          description: 'The source of the finance event. Suggested values: `Merchant`.'
          examples:
            - Merchant
        type:
          type: string
          title: Type
          description: >-
            The type of finance event. Suggested values: `order`, `return`,
            `renew`.
          examples:
            - order
        timestamp:
          type: string
          format: date-time
          title: Timestamp
          description: UTC ISO 8601
        retailCurrency:
          type: string
          title: Retailcurrency
          description: ISO 3
        retailPrice:
          type: number
          title: Retailprice
          description: As per standard price element, including tax
        retailPriceTax:
          type: number
          title: Retailpricetax
          description: As per standard price element, tax included in the retailPrice
        offerPrice:
          type: number
          title: Offerprice
          description: As per standard price element, including tax
        offerPriceTax:
          type: number
          title: Offerpricetax
          description: As per standard price element, tax included in the offerPrice
        notes:
          type: string
          maxLength: 255
          title: Notes
          description: Free text field, max 255 characters
      type: object
      required:
        - source
        - type
        - timestamp
      title: FinanceData
      description: Finance data.
    UpdateParameters:
      properties:
        action:
          $ref: '#/components/schemas/Action'
          description: >-
            The action the reseller should take next


            * NAVIGATE_TO_URL: redirect to the URL provided in the `url`
            parameter.
        url:
          type: string
          title: Url
          description: >-
            The activation url provided by the content provider. Redirect the
            customer to this link to continue the activation process.
      type: object
      title: UpdateParameters
      description: >-
        Activation parameters returned by the update entitlement response
        (camelCase).


        The update response only ever emits `action` and `url`; `urlExpiry` is
        not

        populated on this path (see reseller-api-v1 update handler).
    ErrorMetadata:
      properties:
        responseMessageFrom:
          $ref: '#/components/schemas/ErrorOriginator'
          description: |
            The originator of the error (either Bango or the content provider)

            * `BANGO`
            * `MERCHANT`
      type: object
      required:
        - responseMessageFrom
      title: ErrorMetadata
      description: Error metadata.
    CommunicationInformation:
      properties:
        msisdn:
          anyOf:
            - type: string
            - type: 'null'
          title: Msisdn
          description: >-
            A mobile phone number that can be used to contact the consumer, with
            international prefix
        emailAddress:
          anyOf:
            - type: string
            - type: 'null'
          title: Emailaddress
          description: An email address that can be used to contact the consumer.
      type: object
      title: CommunicationInformation
      description: Communication information.
    ClientDevice:
      properties:
        type:
          $ref: '#/components/schemas/DeviceType'
          description: >
            The type of device. This field is mandatory if clientDevice is being
            provided.


            * `STB`

            * `MOBILE`

            * `DESKTOP`

            * `TABLET`
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: The unique id of the device
        typeId:
          anyOf:
            - type: string
            - type: 'null'
          title: Typeid
          description: The common id for the type of device
        modelName:
          anyOf:
            - type: string
            - type: 'null'
          title: Modelname
          description: The model name of the device
        modelNumber:
          anyOf:
            - type: string
            - type: 'null'
          title: Modelnumber
          description: The model number of the device
        serialNumber:
          anyOf:
            - type: string
            - type: 'null'
          title: Serialnumber
          description: The serial number of the device
        osType:
          anyOf:
            - type: string
            - type: 'null'
          title: Ostype
          description: The operating system of the device
        osVersion:
          anyOf:
            - type: string
            - type: 'null'
          title: Osversion
          description: The version of the operating system of the device
        macAddress:
          anyOf:
            - type: string
            - type: 'null'
          title: Macaddress
          description: The MAC address of the device
        browser:
          anyOf:
            - type: string
            - type: 'null'
          title: Browser
          description: The browser being used
      type: object
      required:
        - type
      title: ClientDevice
      description: Client device.
    Source:
      properties:
        channelType:
          $ref: '#/components/schemas/ChannelType'
          title: Channeltype
          description: |
            The channel the customer used to get the offer. Allowed values:

            * `Retail`
            * `SMS`
            * `App`
            * `Website`
            * `Email`
            * `Call Centre`
            * `Mobile`
            * `Set Top Box`
            * `Other`
        campaignRef:
          anyOf:
            - type: string
            - type: 'null'
          title: Campaignref
          description: The reference of the campaign that attracted the customer
        referrer:
          anyOf:
            - type: string
            - type: 'null'
          title: Referrer
          description: The origin of the customer's request
        bundleId:
          anyOf:
            - type: string
            - type: 'null'
          title: Bundleid
          description: Identifies the bundle the entitlement is part of
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: The customer's country
        region:
          anyOf:
            - type: string
            - type: 'null'
          title: Region
          description: The customer's regional area or code
        brand:
          anyOf:
            - type: string
            - type: 'null'
          title: Brand
          description: The brand
      type: object
      title: Source
      description: Entitlement source.
    Action:
      type: string
      enum:
        - NAVIGATE_TO_URL
      title: Action
      description: Activation actions.
    ErrorOriginator:
      type: string
      enum:
        - BANGO
        - MERCHANT
      title: ErrorOriginator
      description: Error originator.
    DeviceType:
      type: string
      enum:
        - STB
        - MOBILE
        - DESKTOP
        - TABLET
      title: DeviceType
      description: Client device type.
    ChannelType:
      type: string
      enum:
        - Retail
        - SMS
        - App
        - Website
        - Email
        - Call Centre
        - Mobile
        - Set Top Box
        - Other
      title: ChannelType
      description: The channel the customer used to get the offer.
  securitySchemes:
    XApiKey:
      type: apiKey
      in: header
      name: x-api-key
    BasicAuth:
      type: http
      scheme: basic
    OAuth2:
      type: oauth2
      description: >-
        Bango uses
        https://www.oauth.com/oauth2-servers/access-tokens/client-credentials/.
        Please note that when requesting a token, we only support the option to
        send the client secret in the request body. The token URL is for
        production. In the sandbox, use the sandbox authentication service at
        https://sandbox.auth.bango.com.
      flows:
        clientCredentials:
          scopes:
            any: >-
              grants Bango access to the merchant system based on merchant
              defined rules
          tokenUrl: https://auth.bango.com/oauth2/token

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.