Piloterr Costco API

The Costco API from Piloterr — 2 operation(s) for costco.

GitHub OpenAPI

Operations 4

POST /v2/costco/search Costco Search #
GET /v2/costco/product Costco Product #
POST /v2/costco/product Costco Product #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/piloterr-com:piloterr-com-costco-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

piloterr-com-costco-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Piloterr API Reference Costco API
  description: Complete API reference documentation.
  version: 1.0.0
servers:
- url: https://api.piloterr.com
  description: API Server
tags:
- name: Costco
paths:
  /v2/costco/search:
    get:
      summary: Costco Search
      description: 'Costco Search API: search product listings by keyword or URL across 13 regional Costco sites. Returns prices, availability, review counts and pagination via browser rendering.


        **Credit cost:** 2 credits per call'
      operationId: get-costco-search
      security:
      - ApiKeyAuth: []
      parameters:
      - name: query
        in: query
        required: true
        description: 'Search keyword or full regional search URL.


          **Examples:**


          ```

          home

          ```


          ```

          home + region=fr

          ```


          ```

          https://www.costco.co.uk/search?text=sonos

          ```


          ```

          https://www.costco.ca/CatalogSearch?keyword=home&currentPage=2

          ```


          Full URLs auto-detect region and pagination format. Use **Costco Product** on any result `url` for PDP details.'
        schema:
          type: string
          description: 'Search keyword or full regional search URL.


            **Examples:**


            ```

            home

            ```


            ```

            home + region=fr

            ```


            ```

            https://www.costco.co.uk/search?text=sonos

            ```


            ```

            https://www.costco.ca/CatalogSearch?keyword=home&currentPage=2

            ```


            Full URLs auto-detect region and pagination format. Use **Costco Product** on any result `url` for PDP details.'
      - name: region
        in: query
        required: false
        description: 'Regional Costco site. Accepts a region code (`us`, `fr`, `ca`, `uk`, …) or full host (`www.costco.fr`). Defaults to US (`www.costco.com`) when omitted.


          **Examples:**


          ```

          fr

          ```


          ```

          ca

          ```


          ```

          www.costco.co.uk

          ```'
        schema:
          type: string
          description: 'Regional Costco site. Accepts a region code (`us`, `fr`, `ca`, `uk`, …) or full host (`www.costco.fr`). Defaults to US (`www.costco.com`) when omitted.


            **Examples:**


            ```

            fr

            ```


            ```

            ca

            ```


            ```

            www.costco.co.uk

            ```'
      - name: page
        in: query
        required: false
        description: 1-based page number override. Uses `currentPage` (most regions) or `page` (UK) when rebuilding pagination URLs.
        schema:
          type: number
          minimum: 1
          maximum: 500
          description: 1-based page number override. Uses `currentPage` (most regions) or `page` (UK) when rebuilding pagination URLs.
      - name: return_page_source
        in: query
        required: false
        description: 'When `true`, return the raw HTML page source as `{"result": "..."}` instead of structured JSON. Defaults to `false`.'
        schema:
          type: boolean
          description: 'When `true`, return the raw HTML page source as `{"result": "..."}` instead of structured JSON. Defaults to `false`.'
      - $ref: '#/components/parameters/fields'
      - $ref: '#/components/parameters/is_async'
      - $ref: '#/components/parameters/soft_fail'
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  results:
                    type: array
                    items:
                      type: object
                      properties:
                        url:
                          type: string
                        price:
                          type: number
                        title:
                          type: string
                        region:
                          type: string
                        currency:
                          type: string
                        image_url:
                          type: string
                        product_id:
                          type: string
                        availability:
                          type: string
                        review_count:
                          type: integer
                  pagination:
                    type: object
                    properties:
                      next:
                        type: string
                      page:
                        type: integer
                      region:
                        type: string
                      per_page:
                        type: integer
                      total_pages:
                        type: integer
                      total_results:
                        type: integer
              examples:
                Search 'home' on costco.com (page 1):
                  value:
                    results:
                    - url: https://www.costco.com/mohawk-home-6mm-thick-94in-x-478in-22-mil-waterproof-luxury-vinyl-plank-flooring-1565-sq-ftctn.product.4000266385.html
                      price: 40.99
                      title: Mohawk Home 6MM Thick 9.4in X 47.8in 22 MIL Waterproof Luxury Vinyl Plank Flooring (15.65 sq ft/ctn)
                      region: www.costco.com
                      currency: USD
                      image_url: https://bfasset.costco-static.com/U447IH35/as/6wxn2893r8g35r5p98jnkw2v/4000266385-847_tudoroak_1?auto=webp&format=jpg
                      product_id: '4000266385'
                      availability: delivery
                      review_count: 84
                    pagination:
                      next: https://www.costco.com/s?keyword=home&currentPage=2
                      page: 1
                      region: www.costco.com
                      per_page: 24
                      total_pages: 36
                      total_results: 860
        '400':
          description: Bad Request — missing or invalid parameters.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Bad Request
        '401':
          description: Unauthorized — the API key is missing, invalid, inactive, or expired, or a rate limit was exceeded (`Rate limit exceeded…` message).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                invalidKey:
                  value:
                    error: Invalid API Key
                planRateLimit:
                  value:
                    error: 'Rate limit exceeded: You''ve exceeded the per second rate limit on your subscription'
                keyQuota:
                  value:
                    error: 'Rate limit exceeded for the API key: quota monthly'
        '402':
          description: Payment Required — your subscription or credit balance is insufficient.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Payment required
        '500':
          description: Internal Server Error — something went wrong on our side.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Internal Error
      tags:
      - Costco
    post:
      summary: Costco Search
      description: 'Costco Search API: search product listings by keyword or URL across 13 regional Costco sites. Returns prices, availability, review counts and pagination via browser rendering.


        **Credit cost:** 2 credits per call'
      operationId: post-costco-search
      security:
      - ApiKeyAuth: []
      parameters:
      - $ref: '#/components/parameters/fields'
      - $ref: '#/components/parameters/is_async'
      - $ref: '#/components/parameters/soft_fail'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                query:
                  type: string
                  description: 'Search keyword or full regional search URL.


                    **Examples:**


                    ```

                    home

                    ```


                    ```

                    home + region=fr

                    ```


                    ```

                    https://www.costco.co.uk/search?text=sonos

                    ```


                    ```

                    https://www.costco.ca/CatalogSearch?keyword=home&currentPage=2

                    ```


                    Full URLs auto-detect region and pagination format. Use **Costco Product** on any result `url` for PDP details.'
                region:
                  type: string
                  description: 'Regional Costco site. Accepts a region code (`us`, `fr`, `ca`, `uk`, …) or full host (`www.costco.fr`). Defaults to US (`www.costco.com`) when omitted.


                    **Examples:**


                    ```

                    fr

                    ```


                    ```

                    ca

                    ```


                    ```

                    www.costco.co.uk

                    ```'
                page:
                  type: number
                  minimum: 1
                  maximum: 500
                  description: 1-based page number override. Uses `currentPage` (most regions) or `page` (UK) when rebuilding pagination URLs.
                return_page_source:
                  type: boolean
                  description: 'When `true`, return the raw HTML page source as `{"result": "..."}` instead of structured JSON. Defaults to `false`.'
              required:
              - query
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  results:
                    type: array
                    items:
                      type: object
                      properties:
                        url:
                          type: string
                        price:
                          type: number
                        title:
                          type: string
                        region:
                          type: string
                        currency:
                          type: string
                        image_url:
                          type: string
                        product_id:
                          type: string
                        availability:
                          type: string
                        review_count:
                          type: integer
                  pagination:
                    type: object
                    properties:
                      next:
                        type: string
                      page:
                        type: integer
                      region:
                        type: string
                      per_page:
                        type: integer
                      total_pages:
                        type: integer
                      total_results:
                        type: integer
              examples:
                Search 'home' on costco.com (page 1):
                  value:
                    results:
                    - url: https://www.costco.com/mohawk-home-6mm-thick-94in-x-478in-22-mil-waterproof-luxury-vinyl-plank-flooring-1565-sq-ftctn.product.4000266385.html
                      price: 40.99
                      title: Mohawk Home 6MM Thick 9.4in X 47.8in 22 MIL Waterproof Luxury Vinyl Plank Flooring (15.65 sq ft/ctn)
                      region: www.costco.com
                      currency: USD
                      image_url: https://bfasset.costco-static.com/U447IH35/as/6wxn2893r8g35r5p98jnkw2v/4000266385-847_tudoroak_1?auto=webp&format=jpg
                      product_id: '4000266385'
                      availability: delivery
                      review_count: 84
                    pagination:
                      next: https://www.costco.com/s?keyword=home&currentPage=2
                      page: 1
                      region: www.costco.com
                      per_page: 24
                      total_pages: 36
                      total_results: 860
        '400':
          description: Bad Request — missing or invalid parameters.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Bad Request
        '401':
          description: Unauthorized — the API key is missing, invalid, inactive, or expired, or a rate limit was exceeded (`Rate limit exceeded…` message).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                invalidKey:
                  value:
                    error: Invalid API Key
                planRateLimit:
                  value:
                    error: 'Rate limit exceeded: You''ve exceeded the per second rate limit on your subscription'
                keyQuota:
                  value:
                    error: 'Rate limit exceeded for the API key: quota monthly'
        '402':
          description: Payment Required — your subscription or credit balance is insufficient.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Payment required
        '500':
          description: Internal Server Error — something went wrong on our side.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Internal Error
      tags:
      - Costco
  /v2/costco/product:
    get:
      summary: Costco Product
      description: 'Costco Product API: fetch full product page data from a product ID or URL across regional Costco sites. Returns pricing, availability, ratings, images and breadcrumbs via browser rendering.


        **Credit cost:** 2 credits per call'
      operationId: get-costco-product
      security:
      - ApiKeyAuth: []
      parameters:
      - name: query
        in: query
        required: true
        description: 'Costco product ID or full product URL.


          **Examples:**


          ```

          4000266385

          ```


          ```

          4000268598 + region=ca

          ```


          ```

          https://www.costco.com/p/-/mohawk-home-6mm-thick-94in-x-478in-22-mil-waterproof-luxury-vinyl-plank-flooring-1565-sq-ftctn/4000266385

          ```


          ```

          https://www.costco.ca/nom.produit.product.4000268598.html

          ```'
        schema:
          type: string
          description: 'Costco product ID or full product URL.


            **Examples:**


            ```

            4000266385

            ```


            ```

            4000268598 + region=ca

            ```


            ```

            https://www.costco.com/p/-/mohawk-home-6mm-thick-94in-x-478in-22-mil-waterproof-luxury-vinyl-plank-flooring-1565-sq-ftctn/4000266385

            ```


            ```

            https://www.costco.ca/nom.produit.product.4000268598.html

            ```'
      - name: region
        in: query
        required: false
        description: 'Regional Costco site. Accepts a region code (`us`, `fr`, `ca`, `uk`, …) or full host (`www.costco.fr`). Defaults to US (`www.costco.com`) when omitted.


          **Examples:**


          ```

          fr

          ```


          ```

          ca

          ```


          ```

          www.costco.co.uk

          ```'
        schema:
          type: string
          description: 'Regional Costco site. Accepts a region code (`us`, `fr`, `ca`, `uk`, …) or full host (`www.costco.fr`). Defaults to US (`www.costco.com`) when omitted.


            **Examples:**


            ```

            fr

            ```


            ```

            ca

            ```


            ```

            www.costco.co.uk

            ```'
      - name: return_page_source
        in: query
        required: false
        description: 'When `true`, return the raw HTML page source as `{"result": "..."}` instead of structured JSON. Defaults to `false`.'
        schema:
          type: boolean
          description: 'When `true`, return the raw HTML page source as `{"result": "..."}` instead of structured JSON. Defaults to `false`.'
      - $ref: '#/components/parameters/fields'
      - $ref: '#/components/parameters/is_async'
      - $ref: '#/components/parameters/soft_fail'
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  url:
                    type: string
                  name:
                    type: string
                  brand:
                    type: string
                  price:
                    type: number
                  images:
                    type: array
                    items:
                      type: string
                  rating:
                    type: number
                  region:
                    type: string
                  currency:
                    type: string
                  image_url:
                    type: string
                  product_id:
                    type: string
                  breadcrumbs:
                    type: array
                    items:
                      type: string
                  description:
                    type: string
                  item_number:
                    type: string
                  availability:
                    type: string
                  review_count:
                    type: integer
              examples:
                Product 4000266385 on costco.com:
                  value:
                    url: https://www.costco.com/p/-/mohawk-home-6mm-thick-94in-x-478in-22-mil-waterproof-luxury-vinyl-plank-flooring-1565-sq-ftctn/4000266385
                    name: Mohawk Home 6MM Thick 9.4in X 47.8in 22 MIL Waterproof Luxury Vinyl Plank Flooring (15.65 sq ft/ctn)
                    brand: Mohawk Home
                    price: 47.99
                    images:
                    - https://bfasset.costco-static.com/U447IH35/as/44xhpxq9ttr6nhpr4trsx53/4000266385-847_bloomingtonoak_1?auto=webp&format=jpg
                    - https://bfasset.costco-static.com/U447IH35/as/6wxn2893r8g35r5p98jnkw2v/4000266385-847_tudoroak_1?auto=webp&format=jpg&width=727&height=727&fit=bounds&canvas=727%2C727
                    rating: 3.68
                    region: www.costco.com
                    currency: USD
                    image_url: https://bfasset.costco-static.com/U447IH35/as/44xhpxq9ttr6nhpr4trsx53/4000266385-847_bloomingtonoak_1?auto=webp&format=jpg
                    product_id: '4000266385'
                    breadcrumbs:
                    - Home Improvement
                    - Flooring
                    - Vinyl Flooring
                    description: SplashDefense® 100% Waterproof and Water-tight Joints;CleanProtect® Technology with Antimicrobial Properties Built in to Protect the Floor;Wide Plank Vinyl Flooring, 5mm Thick Plank + 1mm Attached Pad for Fast, Easy Installation and No Underlayment Required
                    item_number: '1806569'
                    availability: in_stock
                    review_count: 84
        '400':
          description: Bad Request — missing or invalid parameters.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Bad Request
        '401':
          description: Unauthorized — the API key is missing, invalid, inactive, or expired, or a rate limit was exceeded (`Rate limit exceeded…` message).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                invalidKey:
                  value:
                    error: Invalid API Key
                planRateLimit:
                  value:
                    error: 'Rate limit exceeded: You''ve exceeded the per second rate limit on your subscription'
                keyQuota:
                  value:
                    error: 'Rate limit exceeded for the API key: quota monthly'
        '402':
          description: Payment Required — your subscription or credit balance is insufficient.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Payment required
        '500':
          description: Internal Server Error — something went wrong on our side.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Internal Error
      tags:
      - Costco
    post:
      summary: Costco Product
      description: 'Costco Product API: fetch full product page data from a product ID or URL across regional Costco sites. Returns pricing, availability, ratings, images and breadcrumbs via browser rendering.


        **Credit cost:** 2 credits per call'
      operationId: post-costco-product
      security:
      - ApiKeyAuth: []
      parameters:
      - $ref: '#/components/parameters/fields'
      - $ref: '#/components/parameters/is_async'
      - $ref: '#/components/parameters/soft_fail'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                query:
                  type: string
                  description: 'Costco product ID or full product URL.


                    **Examples:**


                    ```

                    4000266385

                    ```


                    ```

                    4000268598 + region=ca

                    ```


                    ```

                    https://www.costco.com/p/-/mohawk-home-6mm-thick-94in-x-478in-22-mil-waterproof-luxury-vinyl-plank-flooring-1565-sq-ftctn/4000266385

                    ```


                    ```

                    https://www.costco.ca/nom.produit.product.4000268598.html

                    ```'
                region:
                  type: string
                  description: 'Regional Costco site. Accepts a region code (`us`, `fr`, `ca`, `uk`, …) or full host (`www.costco.fr`). Defaults to US (`www.costco.com`) when omitted.


                    **Examples:**


                    ```

                    fr

                    ```


                    ```

                    ca

                    ```


                    ```

                    www.costco.co.uk

                    ```'
                return_page_source:
                  type: boolean
                  description: 'When `true`, return the raw HTML page source as `{"result": "..."}` instead of structured JSON. Defaults to `false`.'
              required:
              - query
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  url:
                    type: string
                  name:
                    type: string
                  brand:
                    type: string
                  price:
                    type: number
                  images:
                    type: array
                    items:
                      type: string
                  rating:
                    type: number
                  region:
                    type: string
                  currency:
                    type: string
                  image_url:
                    type: string
                  product_id:
                    type: string
                  breadcrumbs:
                    type: array
                    items:
                      type: string
                  description:
                    type: string
                  item_number:
                    type: string
                  availability:
                    type: string
                  review_count:
                    type: integer
              examples:
                Product 4000266385 on costco.com:
                  value:
                    url: https://www.costco.com/p/-/mohawk-home-6mm-thick-94in-x-478in-22-mil-waterproof-luxury-vinyl-plank-flooring-1565-sq-ftctn/4000266385
                    name: Mohawk Home 6MM Thick 9.4in X 47.8in 22 MIL Waterproof Luxury Vinyl Plank Flooring (15.65 sq ft/ctn)
                    brand: Mohawk Home
                    price: 47.99
                    images:
                    - https://bfasset.costco-static.com/U447IH35/as/44xhpxq9ttr6nhpr4trsx53/4000266385-847_bloomingtonoak_1?auto=webp&format=jpg
                    - https://bfasset.costco-static.com/U447IH35/as/6wxn2893r8g35r5p98jnkw2v/4000266385-847_tudoroak_1?auto=webp&format=jpg&width=727&height=727&fit=bounds&canvas=727%2C727
                    rating: 3.68
                    region: www.costco.com
                    currency: USD
                    image_url: https://bfasset.costco-static.com/U447IH35/as/44xhpxq9ttr6nhpr4trsx53/4000266385-847_bloomingtonoak_1?auto=webp&format=jpg
                    product_id: '4000266385'
                    breadcrumbs:
                    - Home Improvement
                    - Flooring
                    - Vinyl Flooring
                    description: SplashDefense® 100% Waterproof and Water-tight Joints;CleanProtect® Technology with Antimicrobial Properties Built in to Protect the Floor;Wide Plank Vinyl Flooring, 5mm Thick Plank + 1mm Attached Pad for Fast, Easy Installation and No Underlayment Required
                    item_number: '1806569'
                    availability: in_stock
                    review_count: 84
        '400':
          description: Bad Request — missing or invalid parameters.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Bad Request
        '401':
          description: Unauthorized — the API key is missing, invalid, inactive, or expired, or a rate limit was exceeded (`Rate limit exceeded…` message).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                invalidKey:
                  value:
                    error: Invalid API Key
                planRateLimit:
                  value:
                    error: 'Rate limit exceeded: You''ve exceeded the per second rate limit on your subscription'
                keyQuota:
                  value:
                    error: 'Rate limit exceeded for the API key: quota monthly'
        '402':
          description: Payment Required — your subscription or credit balance is insufficient.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Payment required
        '500':
          description: Internal Server Error — something went wrong on our side.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Internal Error
      tags:
      - Costco
components:
  parameters:
    fields:
      name: fields
      in: query
      required: false
      description: Comma-separated list of response fields to return, with dot notation for nested fields (e.g. `name,location.city`).
      schema:
        type: string
    is_async:
      name: is_async
      in: query
      required: false
      description: 'Run the request as a background job: the API answers `202` with a `job_id` to poll on `GET /v1/jobs/{id}`.'
      schema:
        type: boolean
        default: false
    soft_fail:
      name: soft_fail
      in: query
      required: false
      description: Return HTTP 200 even when the request fails; the error is in the `error` field of the body.
      schema:
        type: boolean
        default: false
  schemas:
    ErrorResponse:
      type: object
      required:
      - error
      properties:
        error:
          type: string
          description: Human-readable error message.
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: Your API key. Include it in the x-api-key header for every request.