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

# Get product and price by sku

> Retrieves product and price details, along with its child products' details if there are any, by specific SKU and priceListId. If price details are not set up previously, it only retrieves the product information; price details are not returned in such cases.



## OpenAPI

````yaml offers_v2_combined get /api-offers/get-product/{sku}
openapi: 3.0.0
info:
  title: Offers v2
  description: >-
    fabric's Offers APIs let you set up and manage stock keeping unit (SKU)
    prices. Its wide range of coupon and promotion features let you design
    discounts ranging from single-use, customer-specific coupons to site-wide
    promotions applicable for all SKUs.
  version: 2.0.0
  contact:
    email: support@fabric.inc
  license:
    url: https://fabric.inc/api-license
    name: fabric API license
servers:
  - url: https://live.copilot.fabric.inc
    description: Production
security:
  - AuthorizationToken: []
tags:
  - name: Price List
    description: >-
      Price list is a collection of items and their assigned prices. An item can
      exist in multiple price lists. This gives you the ability to assign
      different prices to the same item. Price lists let you set currency and
      duration of the prices. For example, if the price list expires, prices of
      items within the price list will also expire. You can configure the
      pricing API to include your default price. <br />When requesting pricelist
      of items or evaluating promotions, you should mention the price list ID
      that you want to use.
  - name: Pricing
    description: >-
      Pricing endpoints let you create and manage price details for one or many
      items. You can configure the pricing API to include your default price
      list in all requests.
  - name: Price Guard
    description: >-
      Price Guard allows you to create and manage more diversified price-kinds
      for the item, such as manufacturer recommended retail price (MSRP),
      minimum advertised price (MAP), floor price, ceiling price, clearance
      price,  and so on.  Price guard works as a protection mechanism against
      any further creation of prices for the item. These endpoints let you
      create and manage such price-kinds.
  - name: Price Kind
    description: >-
      Unlike price guard, price kind endpoint lets you get the fundamental price
      kinds (for example, base price and sale price) that are created while
      setting up the item information.
  - name: Promotion
    description: >-
      Promotion is a discount on an item, cart or shipping method based on set
      conditions. As promotions can be linked to specific price lists, it is
      important to submit the correct price list ID. Promotion endpoints let you
      create and manage discounts that will be applied to all customers' carts
      that meet the required conditions.
  - name: Coupon
    description: >-
      Coupon endpoints let you create and manage coupon codes that customers can
      enter at checkout to receive a discount.
  - name: Dynamic Pricing Engine
    description: >-
      fabric's Dynamic Pricing Engine APIs evaluate promotions and calculate
      prices instantly for the cart items using real-time price calculation
      method, that incorporates the latest information, to provide personalized
      and competitive prices for specific customers. It supports formula based
      custom SKU dynamic pricing, and shows discount breakdown details for
      separate items having separate promotions. It uses the cache information,
      instead of fetching offer details of items from database, to evaluate
      promotions and calculate prices instantly. It is fast, scalable to
      millions of pricing requests per day, and supports complex promotional
      strategies.
  - name: Global exclusion
    description: >-
      Global exclusions let you exclude SKUs from being discounted by active
      promotions. These endpoints let you manage those sku-lists.
  - name: Redemption
    description: Redemption endpoints let you manage the records of coupon redemptions.
  - name: Segment
    description: >-
      Segment endpoints let you target promotions at specific groups of
      customers by linking the promotion to a segment identifier. A customer
      segment is a group of customers that have been given a unique reference to
      easily identify them. They may be grouped in a number of ways such as
      demographics, locations, device type, and so on. fabric Offers supports
      the assignment of a customer segment to a promotion so that the promotion
      is applied only to a specific group of customers. You must enter your
      customer segment identifiers in the *Settings* of the Copilot application.
  - name: Upload price CSV
    description: This endpoint lets you bulk upload price details using a CSV file.
  - name: Product
    description: >-
      Product endpoint lets you get product and price information based on sku.
      Product information is retrieved from Product Catalog and price details
      are retrieved from Offers service.
  - name: Item
    description: >-
      Item endpoints let you get products and prices information based on
      itemId. Product information of an item is retrieved from Product Catalog
      and price details are retrieved from Offers service.
  - name: Attributes
    description: >-
      Attributes refer to a collection of attributes names and their values.
      Using attributes, you can group entities, such as products or shoppers,
      that share similar characteristics, such as dimension, age group,
      location, device type, and more. For example, the shopper segmentation can
      be used to tailor promotions to a specific customer segment by linking the
      promotion to the segment identifier.
  - name: Exports
    description: >-
      fabric Export endpoints let you export data to CSV files based on the
      provided filters.
externalDocs:
  description: Learn more about Offers
  url: https://developer.fabric.inc/docs/offers-overview
paths:
  /api-offers/get-product/{sku}:
    get:
      tags:
        - Product
      summary: Get product and price by sku
      description: >-
        Retrieves product and price details, along with its child products'
        details if there are any, by specific SKU and priceListId. If price
        details are not set up previously, it only retrieves the product
        information; price details are not returned in such cases.
      operationId: getProduct
      parameters:
        - $ref: '#/components/parameters/xSiteContent'
        - in: path
          name: sku
          schema:
            type: string
          required: true
          description: >-
            SKU of the product whose details are to be retrieved. If the product
            has child products, details of the child products are also
            retrieved.
        - in: query
          name: priceListId
          schema:
            type: string
          required: false
          description: >-
            Get product by ID in a given price list. If priceListId is not
            provided, default priceList is selected to search the details for.
            If the SKUdoesn't belong to the default price list, price details
            are not returned.
        - in: query
          name: limit
          schema:
            type: number
            default: 10
            minimum: 1
          required: false
          description: The maximum number of records per page.
        - name: offset
          in: query
          description: >-
            The number of records to skip before returning records. For example,
            when offset is 20 and limit is 10, this endpoint returns records
            from 21 to 30.
          required: false
          schema:
            type: number
            minimum: 0
            default: 0
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/getProductResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/getProductNotFound'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error500'
components:
  parameters:
    xSiteContent:
      name: x-site-context
      in: header
      description: >-
        The `x-site-context` header is a JSON object that contains information
        about the source you wish to pull from. The mandatory `account` is the
        24 character identifier found in Copilot. The `channel` (Sales channel
        ID), `stage` (environment name), and `date` attributes can be used to
        further narrow the scope of your data source.
      required: true
      schema:
        type: string
        example: >-
          {"date": "2023-01-01T00:00:00.000Z", "channel": 12, "account":
          "1234abcd5678efgh9ijklmno","stage":"production"}
  schemas:
    getProductResponse:
      type: object
      properties:
        id:
          type: string
          example: 60c789cfe6e0910008fdcd19
          description: fabric internal ID of the product
        channel:
          type: array
          description: Sales channel of the product
          items:
            type: number
          example:
            - 12
            - 13
        startDate:
          type: string
          format: date-time
          description: Start date of the product
          example: '2021-06-14T16:53:56.020Z'
        endDate:
          type: string
          description: End date of the product
          format: date-time
          example: '2021-06-14T16:53:56.020Z'
        group:
          type: array
          description: ID of the group or category the product belongs to
          items:
            type: string
          example:
            - 60c7894b25c05d00087e882c
        imageSetOnAttributes:
          type: array
          description: Array of URLs to images of different variants or attributes
          items:
            type: string
            example: http://example.com/virpilalphal.jpg
        isDefault:
          type: boolean
          description: >-
            false for parent product<br /> If a parent product has child items,
            true represents the default child item to be displayed, under the
            parent product, on the product listing page.
        isActive:
          type: boolean
          description: >-
            true if the item is active and displayed in the catalog. isActive
            will be true only when state is `READY` <br /> false if the state is
            `DRAFT`, and item is not displayed in the catalog
        isSoftDeleted:
          type: boolean
          description: >-
            true indicates the product is deleted <br /> false indicates the
            product is not deleted
          example: false
        title:
          type: string
          example: Oval shaped table
          description: Title of the product
        itemFamily:
          type: object
          description: Family of products the item belongs to
          properties:
            id:
              type: string
              example: 60c789973af6bf0009c023df
            name:
              type: string
              example: Shoes
        sku:
          type: string
          example: Ovaltable101
          description: SKU of the product
        description:
          type: string
          example: Oval shaped table used as home furniture
          description: Description of the product
        state:
          type: string
          example: READY
          description: >-
            Status of the product. It indicates if the product is ready to be
            published on the product listing page.
        itemId:
          type: number
          example: 1000000269
          description: Item ID of the product
        images:
          type: array
          description: Details of images of the product displayed on copilot UI
          items:
            type: object
            properties:
              id:
                type: string
                description: Image ID
                example: 5fd7577251a93f0007e48383
              order:
                type: number
                description: Image sequence number
                example: 0
              label:
                type: string
                example: >-
                  https://abchome-xpm-images.s3.amazonaws.com/12.01.20+Giving+Tuesday/Homepage/HP_HolidaySix_GI_1.jpg?w=1067
              source:
                type: array
                description: Source of product images
                items:
                  type: object
                  properties:
                    id:
                      type: string
                      example: 5fd7577251a93f0007e48383
                    url:
                      type: string
                      example: >-
                        https://abchome-xpm-images.s3.amazonaws.com/12.01.20+Giving+Tuesday/Homepage/HP_HolidaySix_GI_1.jpg?w=1067
        attributes:
          type: array
          description: Details of product attributes if any
          items:
            type: object
            properties:
              attributeGroupId:
                type: string
                description: >-
                  Attribute group ID. Related attributes are grouped for easy
                  identification and maintenance
                example: 5fd7577251a93f0007e48383
              value:
                type: string
                example: size
              isDefault:
                type: boolean
                description: >-
                  true indicates this attribute is the default attribute of the
                  product<br /> false indicates this is not the default
                  attribute of the product
              id:
                type: string
                description: attribute ID
                example: 100034567
        variants:
          type: array
          description: Different variants of the product
          items:
            type: string
          example:
            - VARIANT-01
            - VARIANT-55
        createdAt:
          type: string
          format: date-time
          example: '2021-06-14T16:54:39.461Z'
          description: Creation date of the product
        updatedAt:
          type: string
          format: date-time
          example: '2021-06-14T16:54:39.461Z'
          description: Last updated date of the product
        items:
          type: array
          description: Lists fabric objectId of child products if there are any
          items:
            type: object
            properties:
              _id:
                type: string
                description: fabric internal ID
                example: cfbc28dd-26b8-40e6-9c37-f233c5a2d004
        price:
          type: object
          description: Price details of the product if it was setup previously
          properties:
            id:
              type: string
              description: fabric internal ID
              example: 5e31832ccaf608b232bb4cdrr
            isSoftDeleted:
              type: boolean
              description: 'true: price is deleted<br /> false: price is not deleted'
            itemId:
              type: number
              example: 1000000269
              description: Item ID of the product
            offerId:
              type: number
              example: 1074
              description: ID of the created offer for the itemId or itemSku
            createdAt:
              type: string
              description: Creation date of the record
              example: '2020-08-19T10:53:29.918Z'
            updatedAt:
              type: string
              description: Last updated date of the record
              example: '2020-08-19T10:53:29.918Z'
            offers:
              type: array
              description: >-
                Returns offer details for the product if it was created
                previously
              items:
                type: object
                properties:
                  price:
                    type: object
                    description: Offer price details
                    properties:
                      sale:
                        type: number
                        description: Price at which the product is offered for sale
                        example: 0
                      base:
                        type: number
                        description: Minimum fixed price of the product
                        example: 229
                      currency:
                        type: string
                        description: Currency code for the price set for the product
                        example: USD
                  channel:
                    type: number
                    description: Sales channel of the product
                    example: 12
                  startDate:
                    type: string
                    format: date-time
                    description: Offer start date
                    example: '2018-10-19T16:46:45Z'
                  endDate:
                    type: string
                    format: date-time
                    description: Offer end date
                    example: '2099-12-31T00:00:00Z'
                  kind:
                    type: number
                    description: >-
                      PriceKindId. It indicates if the offer price is a
                      promotional offer price or clearance offer price
                    example: 10000001
            query:
              type: object
              description: Pagination information for offers array
              properties:
                limit:
                  description: The maximum number of records per page.
                  type: number
                  example: 10
                  default: 10
                count:
                  type: number
                  description: The total number of records.
                  example: 50
                offset:
                  description: >-
                    The number of records to skip before returning records. For
                    example, when offset is 20 and limit is 10, this endpoint
                    returns records from 21 to 30.
                  type: number
                  example: 0
                  default: 0
        priceRange:
          type: object
          description: Price ranges of the product
          properties:
            min:
              type: number
              description: >-
                Minimum price of the product. The product cannot be sold below
                this price
              example: 35
            max:
              type: number
              description: >-
                Maximum price of the product. The product cannot be sold above
                this price
              example: 12000
        livePrice:
          type: array
          description: Current market price of the product with which the product is sold
          items:
            type: object
            properties:
              price:
                type: object
                properties:
                  base:
                    description: Minimum fixed price of item if any
                    type: number
                    example: 299
                  sale:
                    description: Price at which the product is offered for sale
                    type: number
                    example: 199
                  cost:
                    type: number
                    description: Cost of the item if any
                    example: 149
                  currency:
                    type: string
                    description: Currency of the price
                    example: USD
              channel:
                type: number
                description: Sales channel
                example: 12
              startDate:
                type: string
                format: date-time
                description: Start date and time of the current price of the product
                example: '2099-12-31T10:51:00.000Z'
              endDate:
                type: string
                format: date-time
                description: End date and time of the current price of the product
                example: '2099-12-31T10:51:00.000Z'
              kind:
                type: object
                description: >-
                  Price kind details that indicates if the offer price is a
                  promotion kind price or clearance kind price
                properties:
                  id:
                    type: string
                    description: fabric internal ID
                    example: 5fe35c6244076c5ff4968917
                  name:
                    type: string
                    example: Clearance
                  channel:
                    type: number
                    description: Sales channel
                    example: 12
                  priceKindId:
                    description: >-
                      Pricekind ID. This ID helps to identify if the price is
                      base price or clearance price or any other additional
                      price.
                    type: number
                    example: 12
              offerCode:
                type: number
                description: ID associated with the live price object
                example: 128755531
              range:
                type: object
                description: >-
                  Maximum and minimum price range within which the live price of
                  the product varies depending upon the applicable offers
                properties:
                  min:
                    type: number
                    example: 100
                  max:
                    type: number
                    example: 300
        promoDates:
          type: object
          description: Start date and end date of the offer price
          properties:
            startDate:
              type: string
              format: date-time
              example: '2099-12-31T10:51:00.000Z'
            endDate:
              type: string
              format: date-time
              example: '2099-12-31T10:51:00.000Z'
    getProductNotFound:
      type: object
      properties:
        code:
          description: The error code.
          type: string
          example: PRODUCT_NOT_FOUND
        message:
          description: An error message corresponding to the `code`.
          type: string
          example: Product not found.
    error500:
      type: object
      properties:
        code:
          description: The error code.
          type: string
          example: INTERNAL_SERVER_ERROR
        message:
          description: An error message coressponding to the `code`.
          type: string
          example: Internal server error.
  securitySchemes:
    AuthorizationToken:
      type: http
      scheme: bearer
      bearerFormat: JWT

````