Search…
API Reference
Resources
List all billing info validation rules
How to fetch a collection of billing info validation rules via API
To fetch a collection of billing info validation rules, send a GET request to the /api/billing_info_validation_rules endpoint.

Request

GET https://yourdomain.commercelayer.io/api/billing_info_validation_rules

Example

Request
Response
The following request fetches a collection of billing info validation rules:
1
curl -g -X GET \
2
'https://yourdomain.commercelayer.io/api/billing_info_validation_rules/' \
3
-H 'Accept: application/vnd.api+json' \
4
-H 'Authorization: Bearer your-access-token'
Copied!
On success, the API responds with a 200 OK status code, returning a paginated collection of resource objects:
1
{
2
"data": [
3
{
4
"id": "xYZkjABcde",
5
"type": "billing_info_validation_rules",
6
"links": {
7
"self": "https://yourdomain.commercelayer.io/api/billing_info_validation_rules/xYZkjABcde"
8
},
9
"attributes": {
10
"created_at": "2018-01-01T12:00:00.000Z",
11
"updated_at": "2018-01-01T12:00:00.000Z",
12
"reference": "ANY-EXTERNAL-REFEFERNCE",
13
"reference_origin": "ANY-EXTERNAL-REFEFERNCE-ORIGIN",
14
"metadata": {
15
"foo": "bar"
16
}
17
},
18
"relationships": {
19
"market": {
20
"links": {
21
"self": "https://yourdomain.commercelayer.io/api/billing_info_validation_rules/xYZkjABcde/relationships/market",
22
"related": "https://yourdomain.commercelayer.io/api/billing_info_validation_rules/xYZkjABcde/market"
23
}
24
}
25
},
26
"meta": {
27
"mode": "test"
28
}
29
},
30
{
31
"other": "... 9 billing_info_validation_rules (first page)"
32
}
33
],
34
"meta": {
35
"record_count": 140,
36
"page_count": 14
37
},
38
"links": {
39
"first": "https://yourdomain.commercelayer.io/api/billing_info_validation_rules?page[number]=1&page[size]=10",
40
"next": "https://yourdomain.commercelayer.io/api/billing_info_validation_rules?page[number]=2&page[size]=10",
41
"last": "https://yourdomain.commercelayer.io/api/billing_info_validation_rules?page[number]=14&page[size]=10"
42
}
43
}
Copied!

Sortable attributes

The list of billing info validation rules can be sorted by the following attributes:
  • id
  • created_at
  • updated_at
  • reference
  • reference_origin
Last modified 2mo ago