API Reference
Products
Manage products in your account.
List products
Retrieve all products, optionally filtered by product IDs.
Endpoint: GET /products
Query Parameters:
filter[product_ids](array[number], optional) - Array of product IDs to filter by
Example Request:
1curl -X GET "https://api.test.io/customer/v2/products" \
2 -H "Authorization: Token YOUR_API_TOKEN"Response: 200 OK
1{
2 "products": [
3 {
4 "id": 1,
5 "name": "My Product",
6 "description": "Description of the product",
7 "default_section_id": 2,
8 "sections": [],
9 "connection": null
10 }
11 ]
12}Get product
Retrieve a specific product by ID.
Endpoint: GET /products/{product_id}
Parameters:
product_id(number, required) - ID of the Product
Example Request:
1curl -X GET "https://api.test.io/customer/v2/products/1" \
2 -H "Authorization: Token YOUR_API_TOKEN"Response: 200 OK
1{
2 "product": {
3 "id": 1,
4 "name": "My Product",
5 "description": "Description of the product",
6 "default_section_id": 2,
7 "sections": [],
8 "connection": null
9 }
10}Create product
Create a new product.
Endpoint: POST /products
Request Body:
product(Product Create, required) - Product objecttitle(string, required) - Title of the productdescription(string, optional) - Description of the productproduct_type(ProductType, required) - Type of product. Values:website,mobile_app_ios,mobile_app_android,mobile_app_windows,streaming_app,gamingindustry(ProductIndustry, required) - Industry of the product. Values:retail,media,travel,social,health,sports,education,finance,games,other
Example Request:
1curl -X POST "https://api.test.io/customer/v2/products" \
2 -H "Authorization: Token YOUR_API_TOKEN" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "product": {
6 "title": "My New Product",
7 "description": "Description of my product",
8 "product_type": "website",
9 "industry": "retail"
10 }
11 }'Response: 201 Created
1{
2 "product": {
3 "id": 1,
4 "name": "My New Product",
5 "description": "Description of my product",
6 "default_section_id": 2,
7 "sections": [],
8 "connection": null
9 }
10}Update product
Update an existing product.
Endpoint: PUT /products/{product_id}
Parameters:
product_id(number, required) - ID of the Product
Request Body:
product(Product Update, required) - Product objectdescription(string, optional) - Description of the product
Example Request:
1curl -X PUT "https://api.test.io/customer/v2/products/1" \
2 -H "Authorization: Token YOUR_API_TOKEN" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "product": {
6 "description": "Updated description"
7 }
8 }'Response: 200 OK
1{
2 "product": {
3 "id": 1,
4 "name": "My New Product",
5 "description": "Updated description",
6 "default_section_id": 2,
7 "sections": [],
8 "connection": null
9 }
10}Delete product
Delete a product.
Endpoint: DELETE /products/{product_id}
Parameters:
product_id(number, required) - ID of the Product
Example Request:
1curl -X DELETE "https://api.test.io/customer/v2/products/1" \
2 -H "Authorization: Token YOUR_API_TOKEN"Response: 200 OK
1{
2 "product": {
3 "id": 1,
4 "name": "My New Product",
5 "description": "Updated description",
6 "default_section_id": 2,
7 "sections": [],
8 "connection": null
9 }
10}