{ "id": 5052, "brand_id":549, "name":"New Model A", "approved":false }
GET /models 200 { "pagination": { "per_page": 25, "total_pages": 0, "total_objects": 0 }, "models": [] }
Param name | Description |
---|---|
page optional |
Validations:
|
per_page optional |
Validations:
|
name optional |
List models with names matching the provided string. Validations:
|
name_like optional |
List models with names matching, or similar to, the provided string. Slower, but useful for correcting user input. Validations:
|
brand optional |
Validations:
|
brand_id optional |
Validations:
|
approved optional |
Validations:
|
pending optional |
Validations:
|
in_use optional |
Validations:
|
GET /models/3436 200 { "id": 3436, "name": "O30acb4bb72-ae2a-4f22-93d3-cbf924d5b1d7", "approved": true, "brand_id": 4313 }
Code | Description |
---|---|
400 |
curl -X POST -H "Authorization: XXXX" -H "Content-Type: application/json" -d '{"name": "New Model A", "brand_id": 549}' "https://api.axefax.com/models" Response: { "model":{ "id": 5052, "brand_id":549, "name":"New Model A", "approved":false } }
POST /models { "name": "A-6099b6b808dd-d96f-45fa-921a-9a51f5038d97", "model": { "name": "A-6099b6b808dd-d96f-45fa-921a-9a51f5038d97" } } 201 { "id": 3437, "name": "A-6099b6b808dd-d96f-45fa-921a-9a51f5038d97", "approved": false, "brand_id": null }
Param name | Description |
---|---|
name optional |
Validations:
|
brand_id optional |
Validations:
|
Code | Description |
---|---|
400 |
PATCH /models/3439 { "name": "Stratocaster", "model": { "name": "Stratocaster" } } 202 { "id": 3439, "name": "Stratocaster", "approved": false, "brand_id": 4314 }
Param name | Description |
---|---|
name optional |
Validations:
|
brand_id optional |
Validations:
|
Code | Description |
---|---|
405 |
DELETE /models/3444 { "model": {} } 204