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

# Get a coupon

> Get a coupon. <h3>OAuth</h3>Required scopes: <code>invoices.readonly</code> or <code>invoices</code>



## OpenAPI

````yaml /assets/openapi.json get /discounts/v1/coupons/{id}
openapi: 3.0.2
info:
  title: Spacebring
  version: 1.0.0
  termsOfService: https://www.spacebring.com/terms
servers:
  - url: https://api.spacebring.com
security: []
paths:
  /discounts/v1/coupons/{id}:
    get:
      tags:
        - Discounts
      summary: Get a coupon
      description: >-
        Get a coupon. <h3>OAuth</h3>Required scopes:
        <code>invoices.readonly</code> or <code>invoices</code>
      operationId: getCoupon
      parameters:
        - in: path
          name: id
          description: The id of the coupon
          schema:
            type: string
            format: uuid
          required: true
        - in: header
          name: spacebring-network-id
          schema:
            type: string
            format: uuid
          required: false
          description: >-
            The id of the network. Required when using bearer token
            authentication
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  coupon:
                    $ref: '#/components/schemas/coupon'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/responseError'
      security:
        - BasicAuth: []
        - OAuth2:
            - invoices.readonly
            - invoices
components:
  schemas:
    coupon:
      type: object
      properties:
        amountOff:
          description: Fixed discount amount.
          nullable: true
          type: number
        createDate:
          description: ISO timestamp of when the coupon was created.
          type: string
          format: date-time
        currencyCode:
          description: Currency code for amountOff.
          nullable: true
          type: string
        deleteDate:
          description: ISO timestamp of when the coupon was deleted.
          type: string
          format: date-time
        duration:
          description: How long the coupon discount applies.
          nullable: true
          type: string
          enum:
            - forever
            - once
            - repeating
        durationInMonths:
          description: Duration in months when duration is repeating.
          nullable: true
          type: number
        enabledForCredits:
          description: Whether the coupon applies to credit purchases.
          nullable: true
          type: boolean
        id:
          type: string
          format: uuid
          description: Unique identifier of the coupon.
        limitedItems:
          type: object
          properties:
            enabled:
              type: boolean
              description: Whether item-level limits are enabled.
            values:
              type: array
              items:
                type: object
                properties:
                  id:
                    type: string
                    format: uuid
                    description: Unique identifier of the limited item.
                  title:
                    description: Display name of the limited item.
                    type: string
                  type:
                    type: string
                    enum:
                      - roomBookings
                      - eventSpaceBookings
                      - conferenceRoomBookings
                      - meetingRoomBookings
                      - phoneBoothBookings
                      - stationBookings
                      - studioBookings
                      - hotDeskBookings
                      - dedicatedDeskBookings
                      - parkingBookings
                      - equipmentBookings
                      - eventTickets
                      - shopProducts
                      - packages
                      - subscriptionItems
                    description: Product type of the limited item.
                required:
                  - id
                  - type
                additionalProperties: false
                description: Product or package the coupon is limited to.
              description: Items the coupon applies to when limits are enabled.
          required:
            - enabled
            - values
          additionalProperties: false
          description: Item-level redemption limits.
        limitedRedemption:
          type: object
          properties:
            enabled:
              type: boolean
              description: Whether redemption limits are enabled.
            usage:
              type: number
              description: Current redemption count.
            value:
              type: number
              description: Maximum redemption count.
          required:
            - enabled
            - usage
            - value
          additionalProperties: false
          description: Redemption limits for the coupon.
        locationRef:
          description: ID of the location this coupon belongs to.
          type: string
          format: uuid
        networkRef:
          description: ID of the network this coupon belongs to.
          type: string
          format: uuid
        percentOff:
          description: Percentage discount amount.
          nullable: true
          type: number
        productTypes:
          type: array
          items:
            type: string
            enum:
              - roomBookings
              - eventSpaceBookings
              - conferenceRoomBookings
              - meetingRoomBookings
              - phoneBoothBookings
              - stationBookings
              - studioBookings
              - hotDeskBookings
              - dedicatedDeskBookings
              - parkingBookings
              - equipmentBookings
              - eventTickets
              - shopProducts
              - packages
              - subscriptionItems
          description: Product types the coupon applies to.
        type:
          description: Deprecated coupon category.
          type: string
          enum:
            - creditPackages
            - desks
            - equipment
            - events
            - products
            - rooms
            - subscriptionItems
      required:
        - id
        - limitedItems
        - limitedRedemption
        - productTypes
      additionalProperties: false
    responseError:
      type: object
      properties:
        message:
          type: string
        type:
          type: string
  securitySchemes:
    BasicAuth:
      type: http
      description: >-
        See our [authentication
        documentation](https://www.spacebring.com/docs/api-reference/authentication#basic-authentication)
        for how to authorize your requests
      scheme: basic
    OAuth2:
      type: oauth2
      description: >-
        See our [authentication
        documentation](https://www.spacebring.com/docs/api-reference/authentication#oauth2)
        for how to authorize your requests
      flows:
        authorizationCode:
          authorizationUrl: https://api.spacebring.com/oauth2/authorize
          tokenUrl: https://api.spacebring.com/oauth2/token
          refreshUrl: https://api.spacebring.com/oauth2/token
          scopes:
            benefits.readonly: Read benefits and applications
            benefits: Read and write benefits and applications
            community.readonly: Read community companies and memberships
            community: Read and write community companies and memberships
            events.readonly: Read events and tickets
            events: Read and write events and tickets
            feed.readonly: Read feed posts
            feed: Read and write feed posts
            invoices.readonly: Read contracts, credit notes, discounts and invoices
            invoices: Read and write contract, credit notes, discounts and invoices
            locations.readonly: Read locations
            locations: Read and write locations
            plans.readonly: Read plans
            plans: Read and write plans
            resources.readonly: Read resources and bookings
            resources: Read and write resources and bookings
            subscriptions.readonly: Read subscriptions
            subscriptions: Read and write subscriptions
            shop.readonly: Read products and orders
            shop: Read and write products and orders
            support.readonly: Read support tickets
            support: Read and write support tickets
            transactions.readonly: Read transactions
            transactions: Read and write transactions
            visitors.readonly: Read visitors
            visitors: Read and write visitors

````