Open SidemenuAPI Reference
API Reference
Close Sidemenu

SIM Card Groups

Get all SIM card groupsSimCardGroupsGetAll

get https://api.telnyx.com/v2/sim_card_groups

Get all SIM card groups belonging to the user that match the given filters.

curl -X GET \
  --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer YOUR_API_KEY" \
  --globoff "https://api.telnyx.com/v2/sim_card_groups?page[number]=1&page[size]=20"
Parameters
In query
page[number]
integer (1)
optional

The page number to load

Default: 1
page[size]
integer (1 - 250)
optional

The size of the page

Default: 20
filter[name]
string (uuid)
optional

A valid SIM card group name.

Example: "My Test Group"
Responses
200

Successful response

default

Unexpected error

Success Response
{
  "data": [
    {
      "consumed_data": {
        "amount": 10,
        "unit": "B"
      },
      "created_at": "2018-02-02T22:25:27.521Z",
      "data_limit": 2048,
      "default": true,
      "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
      "name": "My Test Group",
      "record_type": "sim_card_group",
      "updated_at": "2018-02-02T22:25:27.521Z"
    }
  ],
  "meta": {
    "page_number": 2,
    "page_size": 25,
    "total_pages": 3,
    "total_results": 55
  }
}

Create a SIM card groupSimCardGroupsPost

post https://api.telnyx.com/v2/sim_card_groups

Creates a new SIM card group object

curl -X POST \
  --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer YOUR_API_KEY" \
  --data '{"name":"My Test Group","data_limit":2048}' \
  https://api.telnyx.com/v2/sim_card_groups
Parameters
In body
name
string
required

A user friendly name for the SIM card group.

Example: "My Test Group"
data_limit
integer
optional

Upper limit on the amount of data the SIM cards, within the group, can use.

Example: 2048
Responses
200

Successful Response

default

Unexpected error

Success Response
{
  "data": {
    "consumed_data": {
      "amount": 10,
      "unit": "B"
    },
    "created_at": "2018-02-02T22:25:27.521Z",
    "data_limit": 2048,
    "default": true,
    "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
    "name": "My Test Group",
    "record_type": "sim_card_group",
    "updated_at": "2018-02-02T22:25:27.521Z"
  }
}

Get SIM card groupSimCardGroupsGet

get https://api.telnyx.com/v2/sim_card_groups/{id}

Returns the details regarding a specific SIM card group

curl -X GET \
  --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer YOUR_API_KEY" \
  --globoff "https://api.telnyx.com/v2/sim_card_groups/6a09cdc3-8948-47f0-aa62-74ac943d6c58"
Parameters
In path
id
string (uuid)
required

Identifies the resource.

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

Successful Response

default

Unexpected error

Success Response
{
  "data": {
    "consumed_data": {
      "amount": 10,
      "unit": "B"
    },
    "created_at": "2018-02-02T22:25:27.521Z",
    "data_limit": 2048,
    "default": true,
    "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
    "name": "My Test Group",
    "record_type": "sim_card_group",
    "updated_at": "2018-02-02T22:25:27.521Z"
  }
}

Update a SIM card groupSimCardGroupUpdate

patch https://api.telnyx.com/v2/sim_card_groups/{id}

Updates a SIM card group

curl -X PATCH \
  --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer YOUR_API_KEY" \
  --data '{"data_limit":2048,"name":"My Test Group"}' \
  https://api.telnyx.com/v2/sim_card_groups/6a09cdc3-8948-47f0-aa62-74ac943d6c58
Parameters
In path
id
string (uuid)
required

Identifies the resource.

Example: "6a09cdc3-8948-47f0-aa62-74ac943d6c58"
In body
data_limit
integer
optional

Upper limit on the amount of data the SIM cards, within the group, can use.

Example: 2048
name
string
optional

A user friendly name for the SIM card group.

Example: "My Test Group"
Responses
200

Successful Response

default

Unexpected error

Success Response
{
  "data": {
    "consumed_data": {
      "amount": 10,
      "unit": "B"
    },
    "created_at": "2018-02-02T22:25:27.521Z",
    "data_limit": 2048,
    "default": true,
    "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
    "name": "My Test Group",
    "record_type": "sim_card_group",
    "updated_at": "2018-02-02T22:25:27.521Z"
  }
}

Delete a SIM card groupSimCardGroupDelete

delete https://api.telnyx.com/v2/sim_card_groups/{id}

Permanently deletes a SIM card group

curl -X DELETE \
  --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer YOUR_API_KEY" \
  "https://api.telnyx.com/v2/sim_card_groups/6a09cdc3-8948-47f0-aa62-74ac943d6c58"
Parameters
In path
id
string (uuid)
required

Identifies the resource.

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

Successful Response

default

Unexpected error

Success Response
{
  "data": {
    "consumed_data": {
      "amount": 10,
      "unit": "B"
    },
    "created_at": "2018-02-02T22:25:27.521Z",
    "data_limit": 2048,
    "default": true,
    "id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
    "name": "My Test Group",
    "record_type": "sim_card_group",
    "updated_at": "2018-02-02T22:25:27.521Z"
  }
}
Previous: Reporting
Next: SIM Cards

Was this section helpful?