Calls
Product
edit_category
5 min
this call edits a product category the arguments that would be included in the doc are described below basic parameters name type required description action string true edit category group id integer true this designates which project the action should be applied towards doc array true see doc parameters below general doc parameters false true 261,79,84false unhandled content type false unhandled content type unhandled content type unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type unhandled content type unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type false unhandled content type example edit an existing category this is an example which would edit an existing category call curl x post "https //www regpack com/reg/api2/products/" \\ h "content type application/json" \\ h "accept application/json" \\ h "api id 15263" \\ h "api user api admin\@regpacks com" \\ h "api token cd2e514f 7gab 3cde 62fg 51abcd4e7362" \\ d '{ "action" "create", "group id" 100909072, "doc" { "base product type" 1, "product name" "the village vanguard presents bill evans trio", "product price" "10", "product activity start date" "1961 06 21", "product activity end date" "1961 06 21", "product short remarks" "this event will be recorded for later release" } }import requests import json status endpoint = https //www regpack com/reg/api2/products/ headers = { "content type" "application/json", "accept" "application/json", "api id" "15263", "api user" "api admin\@regpacks com", "api token" "cd2e514f 7gab 3cde 62fg 51abcd4e7362", } payload = { "action" "create category", "group id" 100909072, "doc" { "category name" "fall performances", "category id" 251125, "category top remark" "fall performances are below", "category bottom remark" "please note that if you must miss an event, tickets are only transferable to future performances", "category quota ordered" 6, "interchange category" false, "mandatory category" false } } create category json = json dumps(payload) create category response = requests post(url=product endpoint, data=create category json, headers=headers, timeout=10) response { 'success' true, 'doc' { 'cat id' 251125, 'msg' 'category updated successfully', 'msg type' 'success' } }