# Retrieve a subscription item

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /v1/subscription_items/{id}:
    get:
      summary: Retrieve a subscription item
      deprecated: false
      description: ''
      tags:
        - API Reference/Subscription Items
      parameters:
        - name: id
          in: path
          description: ''
          required: true
          schema:
            type: string
        - name: Accept
          in: header
          description: ''
          required: true
          example: application/json
          schema:
            type: string
        - name: Content-Type
          in: header
          description: ''
          required: true
          example: application/json
          schema:
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                x-apifox-refs:
                  01HCCREKGSVECT0FSFGYDWN5AZ:
                    $ref: '#/components/schemas/Subscription%20item'
                    x-apifox-overrides:
                      tax_rates: null
                      billing_thresholds: null
                x-apifox-orders:
                  - 01HCCREKGSVECT0FSFGYDWN5AZ
                properties:
                  id:
                    type: string
                    description: Unique identifier for the object.
                  object:
                    type: string
                    description: >-
                      String representing the object’s type. Objects of the same
                      type share the same value.
                  metadata:
                    type: string
                    description: >-
                      Set of key-value pairs that you can attach to an object.
                      This can be useful for storing additional information
                      about the object in a structured format.
                  price:
                    description: The price the customer is subscribed to.
                    type: object
                    x-apifox-refs:
                      01HMZYXK76H2T05N689SJEYWDW: &ref_0
                        $ref: '#/components/schemas/Price'
                        x-apifox-overrides:
                          unit_amount_decimal: null
                          transform_quantity: null
                          tax_behavior: null
                          custom_unit_amount: null
                    x-apifox-orders:
                      - 01HMZYXK76H2T05N689SJEYWDW
                    properties:
                      id:
                        type: string
                        description: Unique identifier for the object, like "price_xxxx".
                      object:
                        type: string
                        description: '''price'''
                      active:
                        type: boolean
                        description: Whether the price can be used for new purchases.
                      billing_scheme:
                        type: string
                        description: >-
                          Describes how to compute the price per period. Either
                          per_unit or tiered
                        enum:
                          - per_unit
                          - tiered
                        x-apifox-enum:
                          - value: per_unit
                            name: ''
                            description: only per_unit is supported now.
                          - value: tiered
                            name: ''
                            description: ''
                      created:
                        type: integer
                        description: >-
                          Time at which the object was created. Measured in
                          seconds since the Unix epoch.
                      currency:
                        type: string
                        description: 'Three-letter ISO currency code, in uppercase. '
                      livemode:
                        type: boolean
                        description: >-
                          Has the value true if the object exists in live mode
                          or the value false if the object exists in test mode.
                      lookup_key:
                        type: string
                        description: >-
                          A lookup key used to retrieve prices dynamically from
                          a static string. This may be up to 200 characters.
                      metadata:
                        type: object
                        properties: {}
                        x-apifox-orders: []
                        description: >-
                          Set of key-value pairs that you can attach to an
                          object. This can be useful for storing additional
                          information about the object in a structured format.
                        x-apifox-ignore-properties: []
                      nickname:
                        type: string
                        description: >-
                          A brief description of the price, hidden from
                          customers.
                      product:
                        type: string
                        description: The ID of the product this price is associated with.
                      type:
                        type: string
                        description: >-
                          One of one_time or recurring depending on whether the
                          price is for a one-time purchase or a recurring
                          (subscription) purchase.
                        enum:
                          - one_time
                          - recurring
                        x-apifox-enum:
                          - value: one_time
                            name: ''
                            description: only one-time is supported now.
                          - value: recurring
                            name: ''
                            description: ''
                      unit_amount:
                        type: integer
                        description: >-
                          The unit amount in cents to be charged, represented as
                          a whole integer if possible. Only set if
                          billing_scheme=per_unit.
                      recurring:
                        type: object
                        properties:
                          interval:
                            type: string
                            description: >-
                              The frequency at which a subscription is billed.
                              One of day, week, month or year.
                            enum:
                              - day
                              - week
                              - month
                              - year
                            x-apifox-enum:
                              - value: day
                                name: ''
                                description: ''
                              - value: week
                                name: ''
                                description: ''
                              - value: month
                                name: ''
                                description: ''
                              - value: year
                                name: ''
                                description: ''
                          interval_count:
                            type: integer
                            description: >-
                              The number of intervals (specified in the interval
                              attribute) between subscription billings. For
                              example, interval=month and interval_count=3 bills
                              every 3 months.
                          usage_type:
                            type: string
                            description: >-
                              Configures how the quantity per period should be
                              determined.
                            enum:
                              - licensed
                            x-apifox-enum:
                              - value: licensed
                                name: ''
                                description: ''
                        x-apifox-orders:
                          - interval
                          - interval_count
                          - usage_type
                        description: The recurring components of a price
                        required:
                          - interval
                        x-apifox-ignore-properties: []
                      tiers_mode:
                        type: 'null'
                        description: （未实现）
                      tiers:
                        type: array
                        items:
                          type: object
                          properties:
                            up_to:
                              type: string
                              description: >-
                                Specifies the upper bound of this tier. The
                                lower bound of a tier is the upper bound of the
                                previous tier adding one. Use inf to define a
                                fallback tier.
                            flat_amount:
                              type: string
                              description: >-
                                The flat billing amount for an entire tier,
                                regardless of the number of units in the tier.
                            unit_amount:
                              type: string
                              description: >-
                                The per unit billing amount for each individual
                                unit for which this tier applies.
                          x-apifox-orders:
                            - up_to
                            - flat_amount
                            - unit_amount
                          x-apifox-ignore-properties: []
                        description: （未实现）
                    x-apifox-ignore-properties:
                      - id
                      - object
                      - active
                      - billing_scheme
                      - created
                      - currency
                      - livemode
                      - lookup_key
                      - metadata
                      - nickname
                      - product
                      - type
                      - unit_amount
                      - recurring
                      - tiers_mode
                      - tiers
                  quantity:
                    type: integer
                    description: >-
                      The quantity of the plan to which the customer should be
                      subscribed.
                  subscription:
                    type: string
                    description: The subscription this subscription_item belongs to.
                  created:
                    type: string
                    description: >-
                      Time at which the object was created. Measured in seconds
                      since the Unix epoch.
                x-apifox-ignore-properties:
                  - id
                  - object
                  - metadata
                  - price
                  - quantity
                  - subscription
                  - created
          headers: {}
          x-apifox-name: OK
      security:
        - basic: []
      x-apifox-folder: API Reference/Subscription Items
      x-apifox-status: developing
      x-run-in-apifox: https://app.apifox.com/web/project/1296482/apis/api-115695331-run
components:
  schemas:
    Price:
      type: object
      properties:
        id: &ref_1
          type: string
          description: Unique identifier for the object, like "price_xxxx".
        object: &ref_2
          type: string
          description: '''price'''
        active: &ref_3
          type: boolean
          description: Whether the price can be used for new purchases.
        billing_scheme:
          type: string
          description: >-
            Describes how to compute the price per period. Either per_unit or
            tiered
          enum: &ref_4
            - per_unit
            - tiered
          x-apifox-enum:
            - value: per_unit
              name: ''
              description: only per_unit is supported now.
            - value: tiered
              name: ''
              description: ''
        created: &ref_5
          type: integer
          description: >-
            Time at which the object was created. Measured in seconds since the
            Unix epoch.
        currency: &ref_6
          type: string
          description: 'Three-letter ISO currency code, in uppercase. '
        livemode: &ref_7
          type: boolean
          description: >-
            Has the value true if the object exists in live mode or the value
            false if the object exists in test mode.
        lookup_key: &ref_8
          type: string
          description: >-
            A lookup key used to retrieve prices dynamically from a static
            string. This may be up to 200 characters.
        metadata:
          type: object
          properties: {}
          x-apifox-orders: &ref_9 []
          description: >-
            Set of key-value pairs that you can attach to an object. This can be
            useful for storing additional information about the object in a
            structured format.
          x-apifox-ignore-properties: []
        nickname: &ref_10
          type: string
          description: A brief description of the price, hidden from customers.
        product: &ref_11
          type: string
          description: The ID of the product this price is associated with.
        type:
          type: string
          description: >-
            One of one_time or recurring depending on whether the price is for a
            one-time purchase or a recurring (subscription) purchase.
          enum: &ref_12
            - one_time
            - recurring
          x-apifox-enum:
            - value: one_time
              name: ''
              description: only one-time is supported now.
            - value: recurring
              name: ''
              description: ''
        unit_amount: &ref_13
          type: integer
          description: >-
            The unit amount in cents to be charged, represented as a whole
            integer if possible. Only set if billing_scheme=per_unit.
        custom_unit_amount:
          type: 'null'
          description: （未实现）
        recurring:
          type: object
          properties:
            interval:
              type: string
              description: >-
                The frequency at which a subscription is billed. One of day,
                week, month or year.
              enum: &ref_14
                - day
                - week
                - month
                - year
              x-apifox-enum:
                - value: day
                  name: ''
                  description: ''
                - value: week
                  name: ''
                  description: ''
                - value: month
                  name: ''
                  description: ''
                - value: year
                  name: ''
                  description: ''
            interval_count: &ref_15
              type: integer
              description: >-
                The number of intervals (specified in the interval attribute)
                between subscription billings. For example, interval=month and
                interval_count=3 bills every 3 months.
            usage_type:
              type: string
              description: Configures how the quantity per period should be determined.
              enum: &ref_16
                - licensed
              x-apifox-enum:
                - value: licensed
                  name: ''
                  description: ''
          x-apifox-orders: &ref_17
            - interval
            - interval_count
            - usage_type
          description: The recurring components of a price
          required:
            - interval
          x-apifox-ignore-properties: []
        tax_behavior:
          type: string
          description: （未实现）
        tiers_mode: &ref_18
          type: 'null'
          description: （未实现）
        tiers:
          type: array
          items:
            type: object
            properties:
              up_to: &ref_19
                type: string
                description: >-
                  Specifies the upper bound of this tier. The lower bound of a
                  tier is the upper bound of the previous tier adding one. Use
                  inf to define a fallback tier.
              flat_amount: &ref_20
                type: string
                description: >-
                  The flat billing amount for an entire tier, regardless of the
                  number of units in the tier.
              unit_amount: &ref_21
                type: string
                description: >-
                  The per unit billing amount for each individual unit for which
                  this tier applies.
            x-apifox-orders: &ref_22
              - up_to
              - flat_amount
              - unit_amount
            x-apifox-ignore-properties: []
          description: （未实现）
        transform_quantity:
          type: 'null'
          description: （未实现）
        unit_amount_decimal:
          type: string
          description: （未实现）
      x-apifox-orders:
        - id
        - object
        - active
        - billing_scheme
        - created
        - currency
        - livemode
        - lookup_key
        - metadata
        - nickname
        - product
        - type
        - unit_amount
        - custom_unit_amount
        - recurring
        - tax_behavior
        - tiers_mode
        - tiers
        - transform_quantity
        - unit_amount_decimal
      x-apifox-ignore-properties: []
      x-apifox-folder: ''
    Subscription item:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the object.
        object:
          type: string
          description: >-
            String representing the object’s type. Objects of the same type
            share the same value.
        metadata:
          type: string
          description: >-
            Set of key-value pairs that you can attach to an object. This can be
            useful for storing additional information about the object in a
            structured format.
        price:
          description: The price the customer is subscribed to.
          type: object
          x-apifox-refs:
            01HMZYXK76H2T05N689SJEYWDW: *ref_0
          x-apifox-orders:
            - 01HMZYXK76H2T05N689SJEYWDW
          properties:
            id: *ref_1
            object: *ref_2
            active: *ref_3
            billing_scheme:
              type: string
              description: >-
                Describes how to compute the price per period. Either per_unit
                or tiered
              enum: *ref_4
              x-apifox-enum:
                - value: per_unit
                  name: ''
                  description: only per_unit is supported now.
                - value: tiered
                  name: ''
                  description: ''
            created: *ref_5
            currency: *ref_6
            livemode: *ref_7
            lookup_key: *ref_8
            metadata:
              type: object
              properties: {}
              x-apifox-orders: *ref_9
              description: >-
                Set of key-value pairs that you can attach to an object. This
                can be useful for storing additional information about the
                object in a structured format.
              x-apifox-ignore-properties: []
            nickname: *ref_10
            product: *ref_11
            type:
              type: string
              description: >-
                One of one_time or recurring depending on whether the price is
                for a one-time purchase or a recurring (subscription) purchase.
              enum: *ref_12
              x-apifox-enum:
                - value: one_time
                  name: ''
                  description: only one-time is supported now.
                - value: recurring
                  name: ''
                  description: ''
            unit_amount: *ref_13
            recurring:
              type: object
              properties:
                interval:
                  type: string
                  description: >-
                    The frequency at which a subscription is billed. One of day,
                    week, month or year.
                  enum: *ref_14
                  x-apifox-enum:
                    - value: day
                      name: ''
                      description: ''
                    - value: week
                      name: ''
                      description: ''
                    - value: month
                      name: ''
                      description: ''
                    - value: year
                      name: ''
                      description: ''
                interval_count: *ref_15
                usage_type:
                  type: string
                  description: Configures how the quantity per period should be determined.
                  enum: *ref_16
                  x-apifox-enum:
                    - value: licensed
                      name: ''
                      description: ''
              x-apifox-orders: *ref_17
              description: The recurring components of a price
              required:
                - interval
              x-apifox-ignore-properties: []
            tiers_mode: *ref_18
            tiers:
              type: array
              items:
                type: object
                properties:
                  up_to: *ref_19
                  flat_amount: *ref_20
                  unit_amount: *ref_21
                x-apifox-orders: *ref_22
                x-apifox-ignore-properties: []
              description: （未实现）
          x-apifox-ignore-properties:
            - id
            - object
            - active
            - billing_scheme
            - created
            - currency
            - livemode
            - lookup_key
            - metadata
            - nickname
            - product
            - type
            - unit_amount
            - recurring
            - tiers_mode
            - tiers
        quantity:
          type: integer
          description: The quantity of the plan to which the customer should be subscribed.
        subscription:
          type: string
          description: The subscription this subscription_item belongs to.
        billing_thresholds:
          type: object
          properties:
            usage_gte:
              type: integer
              description: >-
                Usage threshold that triggers the subscription to create an
                invoice
          description: >-
            Define thresholds at which an invoice will be sent, and the related
            subscription advanced to a new billing period
          x-apifox-orders:
            - usage_gte
          deprecated: true
          x-apifox-ignore-properties: []
        created:
          type: string
          description: >-
            Time at which the object was created. Measured in seconds since the
            Unix epoch.
        tax_rates:
          type: object
          properties: {}
          description: 未完成
          x-apifox-orders: []
          deprecated: true
          x-apifox-ignore-properties: []
      x-apifox-orders:
        - id
        - object
        - metadata
        - price
        - quantity
        - subscription
        - billing_thresholds
        - created
        - tax_rates
      x-apifox-ignore-properties: []
      x-apifox-folder: ''
  securitySchemes:
    basic:
      type: http
      scheme: basic
servers:
  - url: https://apitest.wooshpay.com
    description: 官网测试
security:
  - basic: []

```
