POST | https://[domain].deskie.io/api/ideas_category.json
{
"ideas_category" : {
"category_title" : "Test category"
}
}
{
"ideas_category" : {
"category_id" : 234,
"category_title" : "Test category",
"active" : true
}
}
curl -u [staff_email]:[api_key] -H "Content-Type: application/json" -X POST -d '{ "ideas_category": { "category_title":"Test category" }}' https://[domain].deskie.io/api/ideas_category.json
GET | https://[domain].deskie.io/api/ideas_category.json
{
"0" : {
"ideas_category" : {
"category_id" : 234,
"category_title" : "Test category 1",
"active" : true
}
},
"1" : {
"ideas_category" : {
"category_id" : 235,
"category_title" : "Test category 2",
"active" : false
}
},
"total_count":10
}
curl -u [staff_email]:[api_key] -H "Content-Type: application/json" -X GET https://[domain].deskie.io/api/ideas_category.json?limit=50&page=2
GET | https://[domain].deskie.io/api/ideas_category/[id].json
{
"ideas_category" : {
"category_id" : 234,
"category_title" : "Test category",
"active" : true
}
}
curl -u [staff_email]:[api_key] -H "Content-Type: application/json" -X GET https://[domain].deskie.io/api/ideas_category/234.json
PUT | https://[domain].deskie.io/api/ideas_category/[id].json
{
"ideas_category" : {
"category_title" : "Test category 2"
}
}
{
"ideas_category" : {
"category_id" : 234,
"category_title" : "Test category 2",
"active" : true
}
}
curl -u [staff_email]:[api_key] -H "Content-Type: application/json" -X PUT -d '{ "ideas_category": { "category_title":"Test category 2" }}' https://[domain].deskie.io/api/ideas_category/234.json
PUT | https://[domain].deskie.io/api/ideas_category/[id]/disable.json
{
"ideas_category" : {
"category_id" : 234,
"category_title" : "Test category 2",
"active" : false
}
}
curl -u [staff_email]:[api_key] -H "Content-Type: application/json" -X PUT -d '' https://[domain].deskie.io/api/ideas_category/234/disable.json
PUT | https://[domain].deskie.io/api/ideas_category/[id]/enable.json
{
"ideas_category" : {
"category_id" : 234,
"category_title" : "Test category 2",
"active" : true,
"created_at" : Mon, 05 May 2014 00:15:17 +0300,
"updated_at" : Tue, 23 Dec 2014 10:55:23 +0200
}
}
curl -u [staff_email]:[api_key] -H "Content-Type: application/json" -X PUT -d '' https://[domain].deskie.io/api/ideas_category/234/enable.json
DELETE | https://[domain].deskie.io/api/ideas_category/[id].json
HTTP Status: 200 OK
curl -u [staff_email]:[api_key] -H "Content-Type: application/json" -X DELETE https://[domain].deskie.io/api/ideas_category/234.json