# Instant Purchase (https://developer.godaddy.com/en/docs/references/rest/auctions/instant-purchase)

***

title: Instant Purchase
description: >-
API for previewing and purchasing closeout auction domains via saved payment
profiles.
full: true
\_openapi:
toc:

* depth: 2
  title: >-
  Retrieve payment profiles eligible for instant purchase for the
  specified customer.
  url: >-
  \#retrieve-payment-profiles-eligible-for-instant-purchase-for-the-specified-customer
* depth: 2
  title: >-
  Preview all-in pricing for a list of closeout auction domains before
  purchase.
  url: >-
  \#preview-all-in-pricing-for-a-list-of-closeout-auction-domains-before-purchase
* depth: 2
  title: >-
  Purchase one or more closeout auction domains using a specified payment
  profile.
  url: >-
  \#purchase-one-or-more-closeout-auction-domains-using-a-specified-payment-profile
  structuredData:
  headings:
  * content: >-
    Retrieve payment profiles eligible for instant purchase for the
    specified customer.
    id: >-
    retrieve-payment-profiles-eligible-for-instant-purchase-for-the-specified-customer
  * content: >-
    Preview all-in pricing for a list of closeout auction domains before
    purchase.
    id: >-
    preview-all-in-pricing-for-a-list-of-closeout-auction-domains-before-purchase
  * content: >-
    Purchase one or more closeout auction domains using a specified
    payment profile.
    id: >-
    purchase-one-or-more-closeout-auction-domains-using-a-specified-payment-profile
    contents: \[]

***

## GET /v1/customers/{customerId}/paymentProfiles

Retrieve payment profiles eligible for instant purchase for the specified customer.

### Path parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `customerId` | string | yes | An identifier for a customer. A special alias `MY` is supported when accessing the authenticated customer's own data. |

### Responses

**200** — Request was successful

Content-Type: `application/json`

Schema:

- object — Response containing payment profiles eligible for instant purchase
  - `paymentProfiles` (required): array — A list of payment profiles eligible for instant purchase
      - items:
          - `paymentProfileId` (required): integer <integer-positive> — Unique identifier for the payment profile
          - `currencyId` (required): string <iso-currency-code> — CurrencyId in which pricing information should be accepted and/or returned
          - `label` (required): string — A display-friendly name for the payment profile (e.g. last 4 digits of card, etc.)
          - `category` (required): string — The payment method category
            - enum: "CREDIT_CARD", "PREPAID"
          - `status` (required): string — The status of the payment profile. Only `ACTIVE` profiles are returned.
            - enum: "ACTIVE"
          - `subCategory` (required): string — The payment method sub-category (e.g. Visa, Mastercard, Prepaid)
          - `expMonth`: integer — Expiration month of the payment method (1-12). Only present for credit/debit cards.
          - `expYear`: integer — Expiration year of the payment method (4-digit). Only present for credit/debit cards.

**400** — Request was malformed

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**401** — Authentication info not sent or invalid

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**403** — Authenticated user is not allowed access

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**429** — Too many requests received within interval

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error
  - `retryAfterSec` (required): integer <integer-positive> — Number of seconds to wait before attempting a similar request

**500** — Internal server error

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

## POST /v1/customers/{customerId}/auctions/purchases/preview

Preview all-in pricing for a list of closeout auction domains before purchase.

### Path parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `customerId` | string | yes | An identifier for a customer. A special alias `MY` is supported when accessing the authenticated customer's own data. |

### Request body (required)

An object containing the list of domain names to preview pricing for

Content-Type: `application/json`

Schema:

- object — Request body for previewing all-in pricing for closeout auction domains
  - `domains` (required): array — A list of domain names to preview pricing for
      - items:

### Responses

**200** — Pricing retrieved for all domains

Content-Type: `application/json`

Schema:

- object — Per-domain pricing preview results
  - `currencyId` (required): string <iso-currency-code> — CurrencyId in which pricing information should be accepted and/or returned
  - `auctions` (required): array — Pricing results for each requested domain
      - items:
          - `domainName` (required): string <aname>
          - `status` (required): string — The result status for this domain
            - enum: "FAILED", "SUCCESS"
          - `auctionId`: integer <integer-positive> — Unique identifier for the auction. Present when the domain has an active closeout auction.
          - `auctionPrice`: integer <currency-micro-unit-positive> — The closeout auction price in micro-units (amount * 10^6). Present when status is SUCCESS.
          - `totalPrice`: integer <currency-micro-unit-positive> — The all-in price in micro-units (auction price + renewal/transfer + ICANN fee + taxes). Present when status is SUCCESS.
          - `failureReason`: string — Machine-readable failure code. Present only when status is FAILED.
            - enum: "AUCTION_NOT_FOUND", "PRICING_UNAVAILABLE"

**207** — Pricing retrieved for some domains; others failed

Content-Type: `application/json`

Schema:

- object — Per-domain pricing preview results
  - `currencyId` (required): string <iso-currency-code> — CurrencyId in which pricing information should be accepted and/or returned
  - `auctions` (required): array — Pricing results for each requested domain
      - items:
          - `domainName` (required): string <aname>
          - `status` (required): string — The result status for this domain
            - enum: "FAILED", "SUCCESS"
          - `auctionId`: integer <integer-positive> — Unique identifier for the auction. Present when the domain has an active closeout auction.
          - `auctionPrice`: integer <currency-micro-unit-positive> — The closeout auction price in micro-units (amount * 10^6). Present when status is SUCCESS.
          - `totalPrice`: integer <currency-micro-unit-positive> — The all-in price in micro-units (auction price + renewal/transfer + ICANN fee + taxes). Present when status is SUCCESS.
          - `failureReason`: string — Machine-readable failure code. Present only when status is FAILED.
            - enum: "AUCTION_NOT_FOUND", "PRICING_UNAVAILABLE"

**400** — Request was malformed

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**401** — Authentication info not sent or invalid

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**403** — Authenticated user is not allowed access

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**422** — Required parameters must be specified in correct format

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**429** — Too many requests received within interval

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error
  - `retryAfterSec` (required): integer <integer-positive> — Number of seconds to wait before attempting a similar request

**500** — Internal server error

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

## POST /v1/customers/{customerId}/auctions/purchases

Purchase one or more closeout auction domains using a specified payment profile.

### Path parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `customerId` | string | yes | An identifier for a customer. A special alias `MY` is supported when accessing the authenticated customer's own data. |

### Request body (required)

The payment profile and list of domains to purchase

Content-Type: `application/json`

Schema:

- object — Request body for purchasing closeout auction domains
  - `currencyId` (required): string <iso-currency-code> — CurrencyId in which pricing information should be accepted and/or returned
  - `paymentProfileId`: integer <integer-positive> — The payment profile to charge for this purchase. Must belong to the authenticated customer and be eligible for instant purchase. If not specified, defaults to the shopper's most recently used supported payment method.
  - `domains` (required): array — A list of domains to purchase with expected pricing and ToS acceptance
      - items:
          - `domainName` (required): string <aname>
          - `totalPrice` (required): integer <currency-micro-unit-positive> — The expected all-in price in micro-units (amount * 10^6) from the preview endpoint. Must match current pricing or the domain will fail with PRICE_MISMATCH.
          - `acceptTos` (required): boolean — Must be true to indicate the customer accepts the terms of service for this purchase.

### Responses

**200** — All domains purchased successfully

Content-Type: `application/json`

Schema:

- object — Purchase result with order details and per-domain status
  - `currencyId` (required): string <iso-currency-code> — CurrencyId in which pricing information should be accepted and/or returned
  - `orderDetails` (required): object — Details of the created order
      - `orderId` (required): string — Unique identifier for the order
  - `auctions` (required): array — Per-domain purchase results
      - items:
          - `domainName` (required): string <aname>
          - `status` (required): string — The result status for this domain
            - enum: "FAILED", "SUCCESS"
          - `auctionId`: integer <integer-positive> — Unique identifier for the auction. Present when the domain has an active closeout auction.
          - `totalPrice`: integer <currency-micro-unit-positive> — The all-in price charged in micro-units (amount * 10^6). Present when status is SUCCESS.
          - `failureReason`: string — Machine-readable failure code. Present only when status is FAILED.
            - enum: "AUCTION_NOT_FOUND", "PRICE_MISMATCH", "PRICING_UNAVAILABLE", "TOS_NOT_ACCEPTED"

**207** — Some domains purchased successfully; others failed

Content-Type: `application/json`

Schema:

- object — Purchase result with order details and per-domain status
  - `currencyId` (required): string <iso-currency-code> — CurrencyId in which pricing information should be accepted and/or returned
  - `orderDetails` (required): object — Details of the created order
      - `orderId` (required): string — Unique identifier for the order
  - `auctions` (required): array — Per-domain purchase results
      - items:
          - `domainName` (required): string <aname>
          - `status` (required): string — The result status for this domain
            - enum: "FAILED", "SUCCESS"
          - `auctionId`: integer <integer-positive> — Unique identifier for the auction. Present when the domain has an active closeout auction.
          - `totalPrice`: integer <currency-micro-unit-positive> — The all-in price charged in micro-units (amount * 10^6). Present when status is SUCCESS.
          - `failureReason`: string — Machine-readable failure code. Present only when status is FAILED.
            - enum: "AUCTION_NOT_FOUND", "PRICE_MISMATCH", "PRICING_UNAVAILABLE", "TOS_NOT_ACCEPTED"

**400** — Request was malformed. Also returned for NO_ELIGIBLE_PAYMENT_PROFILE and UNSUPPORTED_CURRENCY.

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**401** — Authentication info not sent or invalid

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**403** — Authenticated user is not allowed access

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**422** — Required parameters must be specified in correct format. Also returned for PAYMENT_FAILED.

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error

**429** — Too many requests received within interval

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error
  - `retryAfterSec` (required): integer <integer-positive> — Number of seconds to wait before attempting a similar request

**500** — Internal server error

Content-Type: `application/json`

Schema:

- object
  - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
  - `fields`: array — List of the specific fields, and the errors found with their contents
      - items:
          - `code` (required): string <constant> — Short identifier for the error, suitable for indicating the specific error within client code
          - `message`: string — Human-readable, English description of the problem with the contents of the field
          - `path` (required): string <json-path> — <ul>
          - `pathRelated`: string <json-path> — JSONPath referring to a field containing an error, which is referenced by `path`
  - `message`: string — Human-readable, English description of the error
