SIM Card Orders

SIM Card Orders operations

Get all SIM card orders

Get all SIM card orders according to filters.

SecuritybearerAuth
Request
query Parameters
filter[created_at]
string <datetime>

Filter by ISO 8601 formatted date-time string matching resource creation date-time.

Example: filter[created_at]=2018-02-02T22:25:27.521Z
filter[updated_at]
string <datetime>

Filter by ISO 8601 formatted date-time string matching resource last update date-time.

Example: filter[updated_at]=2018-02-02T22:25:27.521Z
filter[quantity]
integer

Filter orders by how many SIM cards were ordered.

Example: filter[quantity]=21
filter[cost.amount]
string

The total monetary amount of the order.

Example: filter[cost.amount]=2.53
filter[cost.currency]
string

Filter by ISO 4217 currency string.

Example: filter[cost.currency]=USD
filter[address.id]
string <int64>

Uniquely identifies the address for the order.

Example: filter[address.id]=1293384261075731499
filter[address.street_address]
string

Returns entries with matching name of the street where the address is located.

Example: filter[address.street_address]=311 W Superior St
filter[address.extended_address]
string

Returns entries with matching name of the supplemental field for address information.

Example: filter[address.extended_address]=Suite 504
filter[address.locality]
string

Filter by the name of the city where the address is located.

Example: filter[address.locality]=Chicago
filter[address.administrative_area]
string

Filter by state or province where the address is located.

Example: filter[address.administrative_area]=IL
filter[address.country_code]
string

Filter by the mobile operator two-character (ISO 3166-1 alpha-2) origin country code.

Example: filter[address.country_code]=US
filter[address.postal_code]
string

Filter by postal code for the address.

Example: filter[address.postal_code]=60654
page[number]
integer >= 1
Default: 1

The page number to load

page[size]
integer [ 1 .. 250 ]
Default: 20

The size of the page

Responses
200

Successful response

Response Schema: application/json
Array of objects (SIMCardOrder)
object (PaginationMeta)
default

Unexpected error

Response Schema: application/json
Array of objects (Error)
Array
code
required
string <int>
title
required
string
detail
string
object
meta
object
get/sim_card_orders
Request samples
Response samples
application/json
{
  • "data": [
    • {
      • "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
      • "record_type": "sim_card_order",
      • "quantity": 21,
      • "cost": {
        • "amount": "2.52",
        • "currency": "USD"
        },
      • "order_address": {
        • "id": "1293384261075731499",
        • "street_address": "311 W Superior St",
        • "extended_address": "Suite 504",
        • "locality": "Chicago",
        • "administrative_area": "IL",
        • "country_code": "US",
        • "postal_code": "60654"
        },
      • "tracking_url": "http://www.example.com/",
      • "status": "pending",
      • "created_at": "2018-02-02T22:25:27.521Z",
      • "updated_at": "2018-02-02T22:25:27.521Z"
      }
    ],
  • "meta": {
    • "total_pages": 3,
    • "total_results": 55,
    • "page_number": 2,
    • "page_size": 25
    }
}

Create a SIM card order

Creates a new order for SIM cards.

SecuritybearerAuth
Request
Request Body schema: application/json
required
address_id
required
string <int64>

Uniquely identifies the address for the order.

quantity
required
integer >= 1

The amount of SIM cards to order.

Responses
200

Successful Response

Response Schema: application/json
object (SIMCardOrder)
id
string <uuid>

Identifies the resource.

record_type
string

Identifies the type of the resource.

quantity
integer >= 1

The amount of SIM cards requested in the SIM card order.

object

An object representing the total cost of the order.

object

An object representing the address information from when the order was submitted.

tracking_url
string <url>

The URL used to get tracking information about the order.

status
string

The current status of the SIM Card order.

  • pending - the order is waiting to be processed.
  • processing - the order is currently being processed.
  • ready_to_ship - the order is ready to be shipped to the specified address.
  • shipped - the order was shipped and is on its way to be delivered to the specified address.
  • delivered - the order was delivered to the specified address.
  • canceled - the order was canceled.

Enum: "pending" "processing" "ready_to_ship" "shipped" "delivered" "canceled"
created_at
string

ISO 8601 formatted date-time indicating when the resource was last created.

updated_at
string

ISO 8601 formatted date-time indicating when the resource was last updated.

default

Unexpected error

Response Schema: application/json
Array of objects (Error)
Array
code
required
string <int>
title
required
string
detail
string
object
meta
object
post/sim_card_orders
Request samples
application/json
{
  • "address_id": "1293384261075731499",
  • "quantity": 23
}
Response samples
application/json
{
  • "data": {
    • "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
    • "record_type": "sim_card_order",
    • "quantity": 21,
    • "cost": {
      • "amount": "2.52",
      • "currency": "USD"
      },
    • "order_address": {
      • "id": "1293384261075731499",
      • "street_address": "311 W Superior St",
      • "extended_address": "Suite 504",
      • "locality": "Chicago",
      • "administrative_area": "IL",
      • "country_code": "US",
      • "postal_code": "60654"
      },
    • "tracking_url": "http://www.example.com/",
    • "status": "pending",
    • "created_at": "2018-02-02T22:25:27.521Z",
    • "updated_at": "2018-02-02T22:25:27.521Z"
    }
}

Get a single SIM card order

Get a single SIM card order by its ID.

SecuritybearerAuth
Request
path Parameters
id
required
string <uuid>

Identifies the resource.

Example: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
Responses
200

Successful Response

Response Schema: application/json
object (SIMCardOrder)
id
string <uuid>

Identifies the resource.

record_type
string

Identifies the type of the resource.

quantity
integer >= 1

The amount of SIM cards requested in the SIM card order.

object

An object representing the total cost of the order.

object

An object representing the address information from when the order was submitted.

tracking_url
string <url>

The URL used to get tracking information about the order.

status
string

The current status of the SIM Card order.

  • pending - the order is waiting to be processed.
  • processing - the order is currently being processed.
  • ready_to_ship - the order is ready to be shipped to the specified address.
  • shipped - the order was shipped and is on its way to be delivered to the specified address.
  • delivered - the order was delivered to the specified address.
  • canceled - the order was canceled.

Enum: "pending" "processing" "ready_to_ship" "shipped" "delivered" "canceled"
created_at
string

ISO 8601 formatted date-time indicating when the resource was last created.

updated_at
string

ISO 8601 formatted date-time indicating when the resource was last updated.

404

Resource not found

Response Schema: application/json
code
required
string <int>
title
required
string
detail
string
object
meta
object
default

Unexpected error

Response Schema: application/json
Array of objects (Error)
Array
code
required
string <int>
title
required
string
detail
string
object
meta
object
get/sim_card_orders/{id}
Request samples
Response samples
application/json
{
  • "data": {
    • "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
    • "record_type": "sim_card_order",
    • "quantity": 21,
    • "cost": {
      • "amount": "2.52",
      • "currency": "USD"
      },
    • "order_address": {
      • "id": "1293384261075731499",
      • "street_address": "311 W Superior St",
      • "extended_address": "Suite 504",
      • "locality": "Chicago",
      • "administrative_area": "IL",
      • "country_code": "US",
      • "postal_code": "60654"
      },
    • "tracking_url": "http://www.example.com/",
    • "status": "pending",
    • "created_at": "2018-02-02T22:25:27.521Z",
    • "updated_at": "2018-02-02T22:25:27.521Z"
    }
}

Preview SIM card orders

Preview SIM card order purchases.

SecuritybearerAuth
Request
Request Body schema: application/json
quantity
required
integer >= 1

The amount of SIM cards that the user would like to purchase in the SIM card order.

address_id
required
string <int64>

Uniquely identifies the address for the order.

Responses
202

Successful response

Response Schema: application/json
object (SIMCardOrderPreview)
object
object
object
record_type
string

Identifies the type of the resource.

quantity
integer

The amount of SIM cards requested in the SIM card order.

422

Unprocessable entity. Check the 'detail' field in response for details.

Response Schema: application/json
Array of objects (Error)
Array
code
required
string <int>
title
required
string
detail
string
object
meta
object
post/sim_card_order_preview
Request samples
application/json
{
  • "quantity": 21,
  • "address_id": "1293384261075731499"
}
Response samples
application/json
{
  • "data": {
    • "total_cost": {
      • "amount": "2.32",
      • "currency": "USD"
      },
    • "shipping_cost": {
      • "amount": "2.32",
      • "currency": "USD"
      },
    • "sim_cards_cost": {
      • "amount": "2.32",
      • "currency": "USD"
      },
    • "record_type": "sim_card_order_preview",
    • "quantity": 21
    }
}