# List subscriptions for a contact

`GET /contacts/{contact_id}/subscriptions`

> This is a subset of the full specification, limited to the `GET /contacts/{contact_id}/subscriptions` operation.
>
> You can find the full specification here: /_bundle/docs/references/@2.11/rest-api/api.intercom.io.yaml

```yaml
openapi: 3.0.1
info:
  title: Intercom API
  version: '2.11'
  description: This is a subset of the full specification, limited to the `GET /contacts/{contact_id}/subscriptions` operation.
  contact:
    name: Intercom Developer Hub
    url: https://developers.intercom.com
  license:
    name: MIT
    url: https://spdx.org/licenses/MIT
servers:
  - url: https://api.intercom.io
    description: The production API server
  - url: https://api.eu.intercom.io
    description: The european API server
  - url: https://api.au.intercom.io
    description: The australian API server
security:
  - bearerAuth: []
tags:
  - name: Contacts
    description: Everything about your contacts
  - name: Subscription Types
    description: Everything about subscription types
paths:
  /contacts/{contact_id}/subscriptions:
    get:
      summary: List subscriptions for a contact
      parameters:
        - name: contact_id
          in: path
          description: The unique identifier for the contact which is given by Intercom
          example: 63a07ddf05a32042dffac965
          required: true
          schema:
            type: string
        - name: Intercom-Version
          in: header
          schema:
            $ref: '#/components/schemas/intercom_version'
      tags:
        - Contacts
        - Subscription Types
      operationId: listSubscriptionsForAContact
      description: |
        You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type.
        This will return a list of Subscription Type objects that the contact is associated with.

        The data property will show a combined list of:

          1.Opt-out subscription types that the user has opted-out from.
          2.Opt-in subscription types that the user has opted-in to receiving.

        **Note:** This endpoint only returns subscriptions where the contact has explicitly configured their preference. Subscriptions that are in the default state — where the contact has not made an explicit opt-in or opt-out choice — are not included in the response.
      responses:
        '200':
          description: Successful
          content:
            application/json:
              examples:
                Successful:
                  value:
                    type: list
                    data:
                      - type: subscription
                        id: '93'
                        state: live
                        consent_type: opt_out
                        default_translation:
                          name: Newsletters
                          description: Lorem ipsum dolor sit amet
                          locale: en
                        translations:
                          - name: Newsletters
                            description: Lorem ipsum dolor sit amet
                            locale: en
                        content_types:
                          - email
                      - type: subscription
                        id: '95'
                        state: live
                        consent_type: opt_in
                        default_translation:
                          name: Newsletters
                          description: Lorem ipsum dolor sit amet
                          locale: en
                        translations:
                          - name: Newsletters
                            description: Lorem ipsum dolor sit amet
                            locale: en
                        content_types:
                          - sms_message
              schema:
                $ref: '#/components/schemas/subscription_type_list'
        '401':
          description: Unauthorized
          content:
            application/json:
              examples:
                Unauthorized:
                  value:
                    type: error.list
                    request_id: 82a95655-569d-4e5d-b0d9-f8a6c7a379f3
                    errors:
                      - code: unauthorized
                        message: Access Token Invalid
              schema:
                $ref: '#/components/schemas/error'
        '404':
          description: Contact not found
          content:
            application/json:
              examples:
                Contact not found:
                  value:
                    type: error.list
                    request_id: 3f481052-cf49-4b95-a492-734223865981
                    errors:
                      - code: not_found
                        message: User Not Found
              schema:
                $ref: '#/components/schemas/error'
components:
  schemas:
    error:
      type: object
      title: Error
      description: The API will return an Error List for a failed request, which will contain one or more Error objects.
      properties:
        type:
          type: string
          description: The type is error.list
          example: error.list
        request_id:
          type: string
          nullable: true
          format: uuid
          description: ''
          example: f93ecfa8-d08a-4325-8694-89aeb89c8f85
        errors:
          type: array
          description: An array of one or more error objects
          items:
            properties:
              code:
                type: string
                description: A string indicating the kind of error, used to further qualify the HTTP response code
                example: unauthorized
              message:
                type: string
                nullable: true
                description: Optional. Human readable description of the error.
                example: Access Token Invalid
              field:
                type: string
                nullable: true
                description: Optional. Used to identify a particular field or query parameter that was in error.
                example: email
            required:
              - code
      required:
        - type
        - errors
    intercom_version:
      description: Intercom API version.</br>By default, it's equal to the version set in the app package.
      type: string
      example: '2.11'
      default: '2.11'
      enum:
        - '1.0'
        - '1.1'
        - '1.2'
        - '1.3'
        - '1.4'
        - '2.0'
        - '2.1'
        - '2.2'
        - '2.3'
        - '2.4'
        - '2.5'
        - '2.6'
        - '2.7'
        - '2.8'
        - '2.9'
        - '2.10'
        - '2.11'
        - Preview
    subscription_type:
      title: Subscription Types
      type: object
      x-tags:
        - Subscription Types
      description: A subscription type lets customers easily opt out of non-essential communications without missing what's important to them.
      properties:
        type:
          type: string
          description: The type of the object - subscription
          example: subscription
        id:
          type: string
          description: The unique identifier representing the subscription type.
          example: '123456'
        state:
          type: string
          description: The state of the subscription type.
          enum:
            - live
            - draft
            - archived
          example: live
        default_translation:
          $ref: '#/components/schemas/translation'
        translations:
          type: array
          description: An array of translations objects with the localised version of the subscription type in each available locale within your translation settings.
          items:
            $ref: '#/components/schemas/translation'
        consent_type:
          type: string
          description: Describes the type of consent.
          enum:
            - opt_out
            - opt_in
          example: opt_in
        content_types:
          type: array
          description: The message types that this subscription supports - can contain `email` or `sms_message`.
          items:
            type: string
            enum:
              - email
              - sms_message
            example: email
      required:
        - type
        - id
        - state
        - default_translation
        - translations
        - consent_type
        - content_types
    subscription_type_list:
      title: Subscription Types
      type: object
      description: A list of subscription type objects.
      properties:
        type:
          type: string
          description: The type of the object
          enum:
            - list
          example: list
        data:
          type: array
          description: A list of subscription type objects associated with the workspace .
          items:
            $ref: '#/components/schemas/subscription_type'
      required:
        - type
        - data
    translation:
      title: Translation
      type: object
      description: A translation object contains the localised details of a subscription type.
      properties:
        name:
          type: string
          description: The localised name of the subscription type.
          example: Announcements
        description:
          type: string
          description: The localised description of the subscription type.
          example: Offers, product and feature announcements
        locale:
          type: string
          description: The two character identifier for the language of the translation object.
          example: en
      required:
        - name
        - description
        - locale
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
```
