Changes for page ONEcount API Documentation
Last modified by Rayaan Ahmed on 2025/02/09 22:20
Summary
-
Page properties (1 modified, 0 added, 0 removed)
-
Objects (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -59,6 +59,11 @@ 59 59 11. Create Engagements 60 60 11. Update Engagements 61 61 11. Add users data to Engagement 62 +1. Segments\\ 63 +11. Get all Segments 64 +11. Get specific segment by segment id 65 +11. Add users to segment 66 +11. Get all segment ids for a user 62 62 63 63 \\ 64 64 ... ... @@ -115,7 +115,7 @@ 115 115 (% class="western" %) 116 116 API will output the response in a JSON format discussed below. 117 117 118 -{{code language="yml" theme="RDark" title="Response" collapse="true"}}123 +{{code language="yml" theme="RDark" title="Response"}} 119 119 { 120 120 "result": { 121 121 "success": "1", ... ... @@ -227,7 +227,7 @@ 227 227 Lookup for user whose question id (1) is equal to supplied value. The users object returned will have value of questions 1 & 2. Here for example assumed to be firstname and last name. 228 228 229 229 (% class="western" %) 230 -Return parameter defines a csvof question id that are requested back in response.235 +Return parameter defines a CSV of question id that are requested back in response. 231 231 ))) 232 232 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 233 233 ((( ... ... @@ -335,13 +335,13 @@ 335 335 336 336 (% style="color: rgb(107,107,107);" %)Request 337 337 338 -{{code language="php" theme="RDark" title="Get All Users Request" collapse="true"}}343 +{{code language="php" theme="RDark" title="Get All Users Request"}} 339 339 <?php 340 340 341 341 $curl = curl_init(); 342 342 343 343 curl_setopt_array($curl, array( 344 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/users',349 + CURLOPT_URL => 'https://api.onecount.net/v2/users', 345 345 CURLOPT_RETURNTRANSFER => true, 346 346 CURLOPT_ENCODING => '', 347 347 CURLOPT_MAXREDIRS => 10, ... ... @@ -364,7 +364,7 @@ 364 364 365 365 \\ 366 366 367 -(% style="color: rgb(107,107,107);" %)Response 372 +(% style="color: rgb(107,107,107);" %)Response 200 OK 368 368 369 369 {{code language="yml" theme="RDark" title="Get All Users Response" collapse="true"}} 370 370 { ... ... @@ -875,13 +875,13 @@ 875 875 876 876 (% style="color: rgb(107,107,107);" %)Request 877 877 878 -{{code language="php" theme="RDark" title="Get specific User Request" collapse="true"}}883 +{{code language="php" theme="RDark" title="Get specific User Request"}} 879 879 <?php 880 880 881 881 $curl = curl_init(); 882 882 883 883 curl_setopt_array($curl, array( 884 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/users/8418',889 + CURLOPT_URL => 'https://api.onecount.net/v2/users/{{OCID}}', 885 885 CURLOPT_RETURNTRANSFER => true, 886 886 CURLOPT_ENCODING => '', 887 887 CURLOPT_MAXREDIRS => 10, ... ... @@ -902,7 +902,7 @@ 902 902 903 903 \\ 904 904 905 -(% style="color: rgb(107,107,107);" %)Response 910 +(% style="color: rgb(107,107,107);" %)Response 200 OK 906 906 907 907 {{code language="yml" theme="RDark" title="Get specific user Response" collapse="true"}} 908 908 { ... ... @@ -973,7 +973,7 @@ 973 973 974 974 ---- 975 975 976 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}981 +{{code language="yml" theme="RDark" title="Body"}} 977 977 {"e":"rayaan@one-count.com","p":"12345"} 978 978 {{/code}} 979 979 ... ... @@ -983,13 +983,13 @@ 983 983 984 984 (% style="color: rgb(107,107,107);" %)Request 985 985 986 -{{code language="php" theme="RDark" title="User login Request" collapse="true"}}991 +{{code language="php" theme="RDark" title="User login Request"}} 987 987 <?php 988 988 989 989 $curl = curl_init(); 990 990 991 991 curl_setopt_array($curl, array( 992 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/users/login',997 + CURLOPT_URL => 'https://api.onecount.net/v2/users/login', 993 993 CURLOPT_RETURNTRANSFER => true, 994 994 CURLOPT_ENCODING => '', 995 995 CURLOPT_MAXREDIRS => 10, ... ... @@ -1011,7 +1011,7 @@ 1011 1011 1012 1012 \\ 1013 1013 1014 -(% style="color: rgb(107,107,107);" %)Response 1019 +(% style="color: rgb(107,107,107);" %)Response 200 OK 1015 1015 1016 1016 {{code language="yml" theme="RDark" title="Login user Response" collapse="true"}} 1017 1017 { ... ... @@ -1058,13 +1058,13 @@ 1058 1058 1059 1059 (% style="color: rgb(107,107,107);" %)Request 1060 1060 1061 -{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"}}1066 +{{code language="php" theme="RDark" title="Lookup user Request"}} 1062 1062 <?php 1063 1063 1064 1064 $curl = curl_init(); 1065 1065 1066 1066 curl_setopt_array($curl, array( 1067 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/users/lookup?2=user_242_6298&return=1%2C2%2C3%2C4',1072 + CURLOPT_URL => 'https://api.onecount.net/v2/users/lookup?2=user_242_6298&return=1,2,3,4', 1068 1068 CURLOPT_RETURNTRANSFER => true, 1069 1069 CURLOPT_ENCODING => '', 1070 1070 CURLOPT_MAXREDIRS => 10, ... ... @@ -1085,7 +1085,7 @@ 1085 1085 1086 1086 \\ 1087 1087 1088 -(% style="color: rgb(107,107,107);" %)Response 1093 +(% style="color: rgb(107,107,107);" %)Response 200 OK 1089 1089 1090 1090 {{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"}} 1091 1091 { ... ... @@ -1141,6 +1141,7 @@ 1141 1141 (% class="western" %) 1142 1142 **POST method should be used to create users.** 1143 1143 1149 +(% class="wrapped" %) 1144 1144 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1145 1145 ((( 1146 1146 (% class="western" %) ... ... @@ -1207,6 +1207,7 @@ 1207 1207 CSV of ONEcount QuestionId's requested back in Users object in response. 1208 1208 ))) 1209 1209 1216 +(% class="wrapped" %) 1210 1210 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1211 1211 ((( 1212 1212 (% class="western" %) ... ... @@ -1244,7 +1244,7 @@ 1244 1244 1245 1245 ---- 1246 1246 1247 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}1254 +{{code language="yml" theme="RDark" title="Body"}} 1248 1248 {"Users":{"PartnerId":1,"Demo":{"1":"testApirayaan7@onecount.net","4":"Rayaan","5":"Ahmed"}},"DedupeColumns":"1","Transactions":[]} 1249 1249 {{/code}} 1250 1250 ... ... @@ -1254,13 +1254,13 @@ 1254 1254 1255 1255 (% style="color: rgb(107,107,107);" %)Request 1256 1256 1257 -{{code language="php" theme="RDark" title="Create User Request" collapse="true"}}1264 +{{code language="php" theme="RDark" title="Create User Request"}} 1258 1258 <?php 1259 1259 1260 1260 $curl = curl_init(); 1261 1261 1262 1262 curl_setopt_array($curl, array( 1263 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/users',1270 + CURLOPT_URL => 'https://api.onecount.net/v2/users', 1264 1264 CURLOPT_RETURNTRANSFER => true, 1265 1265 CURLOPT_ENCODING => '', 1266 1266 CURLOPT_MAXREDIRS => 10, ... ... @@ -1282,7 +1282,7 @@ 1282 1282 1283 1283 \\ 1284 1284 1285 -(% style="color: rgb(107,107,107);" %)Response 1292 +(% style="color: rgb(107,107,107);" %)Response 200 OK 1286 1286 1287 1287 {{code language="yml" theme="RDark" title="Create user Response" collapse="true"}} 1288 1288 { ... ... @@ -1316,6 +1316,7 @@ 1316 1316 (% class="western" %) 1317 1317 **PUT method should be used to update users.** 1318 1318 1326 +(% class="wrapped" %) 1319 1319 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1320 1320 ((( 1321 1321 (% class="western" %) ... ... @@ -1369,6 +1369,7 @@ 1369 1369 RequestDate to use for the demo update. If not provided current date will be used. 1370 1370 ))) 1371 1371 1380 +(% class="wrapped" %) 1372 1372 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1373 1373 ((( 1374 1374 (% class="western" %) ... ... @@ -1406,7 +1406,7 @@ 1406 1406 1407 1407 ---- 1408 1408 1409 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}1418 +{{code language="yml" theme="RDark" title="Body"}} 1410 1410 {"Users":{"Demo":{"6":"title1"}}} 1411 1411 {{/code}} 1412 1412 ... ... @@ -1416,13 +1416,13 @@ 1416 1416 1417 1417 (% style="color: rgb(107,107,107);" %)Request 1418 1418 1419 -{{code language="php" theme="RDark" title="Update User Request" collapse="true"}}1428 +{{code language="php" theme="RDark" title="Update User Request"}} 1420 1420 <?php 1421 1421 1422 1422 $curl = curl_init(); 1423 1423 1424 1424 curl_setopt_array($curl, array( 1425 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/users/{{OCID}}',1434 + CURLOPT_URL => 'https://api.onecount.net/v2/users/{{OCID}}', 1426 1426 CURLOPT_RETURNTRANSFER => true, 1427 1427 CURLOPT_ENCODING => '', 1428 1428 CURLOPT_MAXREDIRS => 10, ... ... @@ -1446,7 +1446,7 @@ 1446 1446 1447 1447 \\ 1448 1448 1449 -(% style="color: rgb(107,107,107);" %)Response 1458 +(% style="color: rgb(107,107,107);" %)Response 200 OK 1450 1450 1451 1451 {{code language="yml" theme="RDark" title="Update user Response" collapse="true"}} 1452 1452 { ... ... @@ -1470,7 +1470,7 @@ 1470 1470 \\ 1471 1471 1472 1472 (% class="western" %) 1473 -**COMPONENT: Questions** 1482 +=== **COMPONENT: Questions** === 1474 1474 1475 1475 (% class="western" %) 1476 1476 All data fields in ONEcount are made up of questions. Questions are configurable on a per-client basis, and no two customer installations will have the same question (ie., field) layout. Therefore, before querying or updating any ONEcount installation, you'll need to get an understanding of the question layout of the installation. This API segment will allow you to query ONEcount to determine the question layout for the installation. It will also allow you to create new questions within the system. This resource does not allow you to update the data for a specific user (see User section). ... ... @@ -1660,13 +1660,13 @@ 1660 1660 1661 1661 (% style="color: rgb(107,107,107);" %)Request 1662 1662 1663 -{{code language="php" theme="RDark" title="Get All Questions Request" collapse="true"}}1672 +{{code language="php" theme="RDark" title="Get All Questions Request"}} 1664 1664 <?php 1665 1665 1666 1666 $curl = curl_init(); 1667 1667 1668 1668 curl_setopt_array($curl, array( 1669 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/questions',1678 + CURLOPT_URL => 'https://api.onecount.net/v2/questions', 1670 1670 CURLOPT_RETURNTRANSFER => true, 1671 1671 CURLOPT_ENCODING => '', 1672 1672 CURLOPT_MAXREDIRS => 10, ... ... @@ -1690,7 +1690,7 @@ 1690 1690 1691 1691 \\ 1692 1692 1693 -(% style="color: rgb(107,107,107);" %)Response 1702 +(% style="color: rgb(107,107,107);" %)Response 200 OK 1694 1694 1695 1695 {{code language="yml" theme="RDark" title="Get All Questions Response" collapse="true"}} 1696 1696 { ... ... @@ -3801,13 +3801,13 @@ 3801 3801 3802 3802 (% style="color: rgb(107,107,107);" %)Request 3803 3803 3804 -{{code language="php" theme="RDark" title="Get specific Question Request" collapse="true"}}3813 +{{code language="php" theme="RDark" title="Get specific Question Request"}} 3805 3805 <?php 3806 3806 3807 3807 $curl = curl_init(); 3808 3808 3809 3809 curl_setopt_array($curl, array( 3810 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/questions/{{QUESTION ID}}',3819 + CURLOPT_URL => 'https://api.onecount.net/v2/questions/{{QUESTION ID}}', 3811 3811 CURLOPT_RETURNTRANSFER => true, 3812 3812 CURLOPT_ENCODING => '', 3813 3813 CURLOPT_MAXREDIRS => 10, ... ... @@ -3828,7 +3828,7 @@ 3828 3828 3829 3829 \\ 3830 3830 3831 -(% style="color: rgb(107,107,107);" %)Response 3840 +(% style="color: rgb(107,107,107);" %)Response 200 OK 3832 3832 3833 3833 {{code language="yml" theme="RDark" title="Get specific question Response" collapse="true"}} 3834 3834 { ... ... @@ -3880,13 +3880,13 @@ 3880 3880 3881 3881 (% style="color: rgb(107,107,107);" %)Request 3882 3882 3883 -{{code language="php" theme="RDark" title="Lookup question by text Request" collapse="true"}}3892 +{{code language="php" theme="RDark" title="Lookup question by text Request"}} 3884 3884 <?php 3885 3885 3886 3886 $curl = curl_init(); 3887 3887 3888 3888 curl_setopt_array($curl, array( 3889 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/questions/lookup?Text=COUNTRY',3898 + CURLOPT_URL => 'https://api.onecount.net/v2/questions/lookup?Text=COUNTRY', 3890 3890 CURLOPT_RETURNTRANSFER => true, 3891 3891 CURLOPT_ENCODING => '', 3892 3892 CURLOPT_MAXREDIRS => 10, ... ... @@ -3907,7 +3907,7 @@ 3907 3907 3908 3908 \\ 3909 3909 3910 -(% style="color: rgb(107,107,107);" %)Response 3919 +(% style="color: rgb(107,107,107);" %)Response 200 OK 3911 3911 3912 3912 {{code language="yml" theme="RDark" title="Lookup question by title Response" collapse="true"}} 3913 3913 { ... ... @@ -5326,13 +5326,13 @@ 5326 5326 5327 5327 (% style="color: rgb(107,107,107);" %)Request 5328 5328 5329 -{{code language="php" theme="RDark" title="Lookup question by Type Request" collapse="true"}}5338 +{{code language="php" theme="RDark" title="Lookup question by Type Request"}} 5330 5330 <?php 5331 5331 5332 5332 $curl = curl_init(); 5333 5333 5334 5334 curl_setopt_array($curl, array( 5335 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/questions/lookup?Type=4',5344 + CURLOPT_URL => 'https://api.onecount.net/v2/questions/lookup?Type=4', 5336 5336 CURLOPT_RETURNTRANSFER => true, 5337 5337 CURLOPT_ENCODING => '', 5338 5338 CURLOPT_MAXREDIRS => 10, ... ... @@ -5353,7 +5353,7 @@ 5353 5353 5354 5354 \\ 5355 5355 5356 -(% style="color: rgb(107,107,107);" %)Response 5365 +(% style="color: rgb(107,107,107);" %)Response 200 OK 5357 5357 5358 5358 {{code language="yml" theme="RDark" title="Lookup question by type Response" collapse="true"}} 5359 5359 { ... ... @@ -8023,7 +8023,7 @@ 8023 8023 8024 8024 ---- 8025 8025 8026 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}8035 +{{code language="yml" theme="RDark" title="Body"}} 8027 8027 {"Text":"Test from API 3","Type":0,"Alias":"Test from API 3"} 8028 8028 {{/code}} 8029 8029 ... ... @@ -8033,13 +8033,13 @@ 8033 8033 8034 8034 (% style="color: rgb(107,107,107);" %)Request 8035 8035 8036 -{{code language="php" theme="RDark" title="Create Question Request" collapse="true"}}8045 +{{code language="php" theme="RDark" title="Create Question Request"}} 8037 8037 <?php 8038 8038 8039 8039 $curl = curl_init(); 8040 8040 8041 8041 curl_setopt_array($curl, array( 8042 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/questions',8051 + CURLOPT_URL => 'https://api.onecount.net/v2/questions', 8043 8043 CURLOPT_RETURNTRANSFER => true, 8044 8044 CURLOPT_ENCODING => '', 8045 8045 CURLOPT_MAXREDIRS => 10, ... ... @@ -8061,7 +8061,7 @@ 8061 8061 8062 8062 \\ 8063 8063 8064 -(% style="color: rgb(107,107,107);" %)Response 8073 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8065 8065 8066 8066 {{code language="yml" theme="RDark" title="Create question Response" collapse="true"}} 8067 8067 { ... ... @@ -8101,7 +8101,7 @@ 8101 8101 8102 8102 ---- 8103 8103 8104 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}8113 +{{code language="yml" theme="RDark" title="Body"}} 8105 8105 {"Text":"Test from API 6","Type":4,"Alias":"Test from API 6", "Choices":[{"Text":"test 1","Value":"test 1"},{"Text":"test 2","Value":"test 2"}]} 8106 8106 {{/code}} 8107 8107 ... ... @@ -8111,13 +8111,13 @@ 8111 8111 8112 8112 (% style="color: rgb(107,107,107);" %)Request 8113 8113 8114 -{{code language="php" theme="RDark" title="Create Question Request" collapse="true"}}8123 +{{code language="php" theme="RDark" title="Create Question Request"}} 8115 8115 <?php 8116 8116 8117 8117 $curl = curl_init(); 8118 8118 8119 8119 curl_setopt_array($curl, array( 8120 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/questions',8129 + CURLOPT_URL => 'https://api.onecount.net/v2/questions', 8121 8121 CURLOPT_RETURNTRANSFER => true, 8122 8122 CURLOPT_ENCODING => '', 8123 8123 CURLOPT_MAXREDIRS => 10, ... ... @@ -8139,7 +8139,7 @@ 8139 8139 8140 8140 \\ 8141 8141 8142 -(% style="color: rgb(107,107,107);" %)Response 8151 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8143 8143 8144 8144 {{code language="yml" theme="RDark" title="Create question Response" collapse="true"}} 8145 8145 { ... ... @@ -8179,7 +8179,7 @@ 8179 8179 8180 8180 ---- 8181 8181 8182 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}8191 +{{code language="yml" theme="RDark" title="Body"}} 8183 8183 {"Text":"Test from API 6 changed","Type":4,"Alias":"Test from API 6 changed", "Choices":[{"Text":"test 1","Value":"test 1"},{"Text":"test 2","Value":"test 2"}]} 8184 8184 {{/code}} 8185 8185 ... ... @@ -8189,13 +8189,13 @@ 8189 8189 8190 8190 (% style="color: rgb(107,107,107);" %)Request 8191 8191 8192 -{{code language="php" theme="RDark" title="Update Question Request" collapse="true"}}8201 +{{code language="php" theme="RDark" title="Update Question Request"}} 8193 8193 <?php 8194 8194 8195 8195 $curl = curl_init(); 8196 8196 8197 8197 curl_setopt_array($curl, array( 8198 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/questions/503',8207 + CURLOPT_URL => 'https://api.onecount.net/v2/questions/{{QUESTION ID}}', 8199 8199 CURLOPT_RETURNTRANSFER => true, 8200 8200 CURLOPT_ENCODING => '', 8201 8201 CURLOPT_MAXREDIRS => 10, ... ... @@ -8219,7 +8219,7 @@ 8219 8219 8220 8220 \\ 8221 8221 8222 -(% style="color: rgb(107,107,107);" %)Response 8231 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8223 8223 8224 8224 {{code language="yml" theme="RDark" title="Update Question Response" collapse="true"}} 8225 8225 { ... ... @@ -8242,7 +8242,7 @@ 8242 8242 \\ 8243 8243 8244 8244 (% class="western" %) 8245 -**COMPONENT: Products** 8254 +=== **COMPONENT: Products** === 8246 8246 8247 8247 (% class="western" %) 8248 8248 This resource is for manipulating products resource. A product can be created, updated or searched. ... ... @@ -8374,13 +8374,13 @@ 8374 8374 8375 8375 (% style="color: rgb(107,107,107);" %)Request 8376 8376 8377 -{{code language="php" theme="RDark" title="Get All Products Request" collapse="true"}}8386 +{{code language="php" theme="RDark" title="Get All Products Request"}} 8378 8378 <?php 8379 8379 8380 8380 $curl = curl_init(); 8381 8381 8382 8382 curl_setopt_array($curl, array( 8383 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/products',8392 + CURLOPT_URL => 'https://api.onecount.net/v2/products', 8384 8384 CURLOPT_RETURNTRANSFER => true, 8385 8385 CURLOPT_ENCODING => '', 8386 8386 CURLOPT_MAXREDIRS => 10, ... ... @@ -8403,7 +8403,7 @@ 8403 8403 8404 8404 \\ 8405 8405 8406 -(% style="color: rgb(107,107,107);" %)Response 8415 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8407 8407 8408 8408 {{code language="yml" theme="RDark" title="Get All Products Response" collapse="true"}} 8409 8409 { ... ... @@ -8662,13 +8662,13 @@ 8662 8662 8663 8663 (% style="color: rgb(107,107,107);" %)Request 8664 8664 8665 -{{code language="php" theme="RDark" title="Get specific Product Request" collapse="true"}}8674 +{{code language="php" theme="RDark" title="Get specific Product Request"}} 8666 8666 <?php 8667 8667 8668 8668 $curl = curl_init(); 8669 8669 8670 8670 curl_setopt_array($curl, array( 8671 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/products/{{Product id}}',8680 + CURLOPT_URL => 'https://api.onecount.net/v2/users/products/{{product id}}', 8672 8672 CURLOPT_RETURNTRANSFER => true, 8673 8673 CURLOPT_ENCODING => '', 8674 8674 CURLOPT_MAXREDIRS => 10, ... ... @@ -8689,7 +8689,7 @@ 8689 8689 8690 8690 \\ 8691 8691 8692 -(% style="color: rgb(107,107,107);" %)Response 8701 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8693 8693 8694 8694 {{code language="yml" theme="RDark" title="Get specific Product Response" collapse="true"}} 8695 8695 { ... ... @@ -8752,13 +8752,13 @@ 8752 8752 8753 8753 (% style="color: rgb(107,107,107);" %)Request 8754 8754 8755 -{{code language="php" theme="RDark" title="Lookup Product Request" collapse="true"}}8764 +{{code language="php" theme="RDark" title="Lookup Product Request"}} 8756 8756 <?php 8757 8757 8758 8758 $curl = curl_init(); 8759 8759 8760 8760 curl_setopt_array($curl, array( 8761 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/products/lookup?Title={{PackageName}}',8770 + CURLOPT_URL => 'https://api.onecount.net/v2/products/lookup?Title={{Product Name}}', 8762 8762 CURLOPT_RETURNTRANSFER => true, 8763 8763 CURLOPT_ENCODING => '', 8764 8764 CURLOPT_MAXREDIRS => 10, ... ... @@ -8779,7 +8779,7 @@ 8779 8779 8780 8780 \\ 8781 8781 8782 -(% style="color: rgb(107,107,107);" %)Response 8791 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8783 8783 8784 8784 {{code language="yml" theme="RDark" title="Lookup Product Response" collapse="true"}} 8785 8785 { ... ... @@ -8811,106 +8811,239 @@ 8811 8811 8812 8812 \\ 8813 8813 8814 -\\ 8823 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 8824 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Create Product(%%) == 8815 8815 8816 - \\8826 +---- 8817 8817 8818 -\\ 8828 +{{panel bgColor="#D3D3D3" width="100%"}} 8829 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/products 8830 +{{/panel}} 8819 8819 8820 - \\8832 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 8821 8821 8822 - \\8834 +---- 8823 8823 8824 - \\8836 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 8825 8825 8826 - \\8838 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 8827 8827 8828 - \\8840 +---- 8829 8829 8830 -\\ 8842 +{{code language="yml" theme="RDark" title="Body"}} 8843 +{"Title":"Test API package creation 2","Description": "Test API package creation 2","Terms":{"Name":"Test term for API 2"},"PrimaryFormId":0} 8844 +{{/code}} 8831 8831 8832 - \\8846 +==== Example ==== 8833 8833 8834 - \\8848 +---- 8835 8835 8836 - \\8850 +(% style="color: rgb(107,107,107);" %)Request 8837 8837 8838 -\\ 8852 +{{code language="php" theme="RDark" title="Create Product Request"}} 8853 + <?php 8839 8839 8840 - \\8855 +$curl = curl_init(); 8841 8841 8842 -\\ 8857 +curl_setopt_array($curl, array( 8858 + CURLOPT_URL => 'https://api.onecount.net/v2/products', 8859 + CURLOPT_RETURNTRANSFER => true, 8860 + CURLOPT_ENCODING => '', 8861 + CURLOPT_MAXREDIRS => 10, 8862 + CURLOPT_TIMEOUT => 0, 8863 + CURLOPT_FOLLOWLOCATION => true, 8864 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 8865 + CURLOPT_CUSTOMREQUEST => 'POST', 8866 + CURLOPT_POSTFIELDS =>'{"Title":"Test API package creation 1","Description": "Test API package creation 1","Terms":{"Name":"Test term for API 1"},"PrimaryFormId":0}', 8867 + CURLOPT_HTTPHEADER => array( 8868 + 'Appkey: {{ONECOUNT API KEY}}' 8869 + ), 8870 +)); 8843 8843 8844 - \\8872 +$response = curl_exec($curl); 8845 8845 8846 -\\ 8874 +curl_close($curl); 8875 +echo $response; 8876 +{{/code}} 8847 8847 8848 8848 \\ 8849 8849 8850 - \\8880 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8851 8851 8852 -\\ 8882 +{{code language="yml" theme="RDark" title="Create Product Response" collapse="true"}} 8883 + { 8884 + "result": { 8885 + "success": "1", 8886 + "error": { 8887 + "code": "", 8888 + "message": "" 8889 + } 8890 + }, 8891 + "Products": [ 8892 + { 8893 + "ProductId": 599 8894 + } 8895 + ] 8896 +} 8897 +{{/code}} 8853 8853 8854 8854 \\ 8855 8855 8856 -\\ 8901 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 8902 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(0, 83, 184)" %)PUT (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %)Update Product(%%) == 8857 8857 8858 - \\8904 +---- 8859 8859 8860 -\\ 8906 +{{panel bgColor="#D3D3D3" width="100%"}} 8907 + (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/products/~{~{Product id}} 8908 +{{/panel}} 8861 8861 8862 - \\8910 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 8863 8863 8864 - \\8912 +---- 8865 8865 8866 - \\8914 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 8867 8867 8868 - \\8916 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 8869 8869 8870 - \\8918 +---- 8871 8871 8872 -\\ 8920 +{{code language="yml" theme="RDark" title="Body"}} 8921 +{"Title":"Test API package 23","Description": "Test API package 23","PrimaryFormId":0} 8922 +{{/code}} 8873 8873 8874 - \\8924 +==== Example ==== 8875 8875 8876 - \\8926 +---- 8877 8877 8878 - \\8928 +(% style="color: rgb(107,107,107);" %)Request 8879 8879 8880 -\\ 8930 +{{code language="php" theme="RDark" title="Update Product Request"}} 8931 +<?php 8881 8881 8882 - \\8933 +$curl = curl_init(); 8883 8883 8884 -\\ 8935 +curl_setopt_array($curl, array( 8936 + CURLOPT_URL => 'https://api.onecount.net/v2/products/{{Product id}}', 8937 + CURLOPT_RETURNTRANSFER => true, 8938 + CURLOPT_ENCODING => '', 8939 + CURLOPT_MAXREDIRS => 10, 8940 + CURLOPT_TIMEOUT => 0, 8941 + CURLOPT_FOLLOWLOCATION => true, 8942 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 8943 + CURLOPT_CUSTOMREQUEST => 'PUT', 8944 + CURLOPT_POSTFIELDS =>'{"Title":"Test API package 1","Description": "Test API package 1","PrimaryFormId":0}', 8945 + CURLOPT_HTTPHEADER => array( 8946 + 'Appkey: {{ONECOUNT API KEY}}' 8947 + ), 8948 +)); 8885 8885 8886 - \\8950 +$response = curl_exec($curl); 8887 8887 8888 -\\ 8952 +curl_close($curl); 8953 +echo $response; 8954 + 8955 +{{/code}} 8889 8889 8890 8890 \\ 8891 8891 8892 - \\8959 +(% style="color: rgb(107,107,107);" %)Response 200 OK 8893 8893 8894 -\\ 8961 +{{code language="yml" theme="RDark" title="Update Product Response" collapse="true"}} 8962 + { 8963 + "result": { 8964 + "success": "1", 8965 + "error": { 8966 + "code": "", 8967 + "message": "" 8968 + } 8969 + }, 8970 + "Products": [ 8971 + { 8972 + "ProductId": 599, 8973 + "Title": "Test API package 1", 8974 + "Description": "Test API package 1" 8975 + } 8976 + ] 8977 +} 8978 +{{/code}} 8895 8895 8896 8896 \\ 8897 8897 8898 -\\ 8982 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 8983 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Attach Resource to Product(%%) == 8899 8899 8900 - \\8985 +---- 8901 8901 8902 -\\ 8987 +{{panel bgColor="#D3D3D3" width="100%"}} 8988 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/products/attachResource 8989 +{{/panel}} 8903 8903 8904 - \\8991 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 8905 8905 8906 - \\8993 +---- 8907 8907 8908 - \\8995 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 8909 8909 8997 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 8998 + 8999 +---- 9000 + 9001 +{{code language="yml" theme="RDark" title="Body"}} 9002 +{"ProductID":"599","ResourceID":"903"} 9003 +{{/code}} 9004 + 9005 +==== Example ==== 9006 + 9007 +---- 9008 + 9009 +(% style="color: rgb(107,107,107);" %)Request 9010 + 9011 +{{code language="php" theme="RDark" title="Attach Resource to Product Request"}} 9012 + <?php 9013 + 9014 +$curl = curl_init(); 9015 + 9016 +curl_setopt_array($curl, array( 9017 + CURLOPT_URL => 'https://api.onecount.net/v2/products/attachResource', 9018 + CURLOPT_RETURNTRANSFER => true, 9019 + CURLOPT_ENCODING => '', 9020 + CURLOPT_MAXREDIRS => 10, 9021 + CURLOPT_TIMEOUT => 0, 9022 + CURLOPT_FOLLOWLOCATION => true, 9023 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 9024 + CURLOPT_CUSTOMREQUEST => 'POST', 9025 + CURLOPT_POSTFIELDS =>'{"ProductID":"599","ResourceID":"903"}', 9026 + CURLOPT_HTTPHEADER => array( 9027 + 'Appkey: {{ONECOUNT API KEY}}' 9028 + ), 9029 +)); 9030 + 9031 +$response = curl_exec($curl); 9032 + 9033 +curl_close($curl); 9034 +echo $response; 9035 +{{/code}} 9036 + 8910 8910 \\ 8911 8911 9039 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9040 + 9041 +{{code language="yml" theme="RDark" title="Create Product Response" collapse="true"}} 9042 + { 9043 + "result": { 9044 + "success": "1", 9045 + "error": { 9046 + "code": "", 9047 + "message": "" 9048 + } 9049 + }, 9050 + "Products": "599" 9051 +} 9052 +{{/code}} 9053 + 8912 8912 (% class="western" %) 8913 -**COMPONENT: Terms** 9055 +=== **COMPONENT: Terms** === 8914 8914 8915 8915 (% class="western" %) 8916 8916 This resource is for manipulating terms resource. A term can be created, updated or searched. ... ... @@ -9007,13 +9007,13 @@ 9007 9007 9008 9008 (% style="color: rgb(107,107,107);" %)Request 9009 9009 9010 -{{code language="php" theme="RDark" title="Get All Terms Request" collapse="true"}}9152 +{{code language="php" theme="RDark" title="Get All Terms Request"}} 9011 9011 <?php 9012 9012 9013 9013 $curl = curl_init(); 9014 9014 9015 9015 curl_setopt_array($curl, array( 9016 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/terms',9158 + CURLOPT_URL => 'https://api.onecount.net/v2/terms', 9017 9017 CURLOPT_RETURNTRANSFER => true, 9018 9018 CURLOPT_ENCODING => '', 9019 9019 CURLOPT_MAXREDIRS => 10, ... ... @@ -9034,7 +9034,7 @@ 9034 9034 9035 9035 \\ 9036 9036 9037 -(% style="color: rgb(107,107,107);" %)Response 9179 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9038 9038 9039 9039 {{code language="yml" theme="RDark" title="Get All Terms Response" collapse="true"}} 9040 9040 { ... ... @@ -9190,13 +9190,13 @@ 9190 9190 9191 9191 (% style="color: rgb(107,107,107);" %)Request 9192 9192 9193 -{{code language="php" theme="RDark" title="Get specific Term Request" collapse="true"}}9335 +{{code language="php" theme="RDark" title="Get specific Term Request"}} 9194 9194 <?php 9195 9195 9196 9196 $curl = curl_init(); 9197 9197 9198 9198 curl_setopt_array($curl, array( 9199 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/terms/{{Term Id}}',9341 + CURLOPT_URL => 'https://api.onecount.net/v2/terms/{{Term Id}}', 9200 9200 CURLOPT_RETURNTRANSFER => true, 9201 9201 CURLOPT_ENCODING => '', 9202 9202 CURLOPT_MAXREDIRS => 10, ... ... @@ -9217,7 +9217,7 @@ 9217 9217 9218 9218 \\ 9219 9219 9220 -(% style="color: rgb(107,107,107);" %)Response 9362 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9221 9221 9222 9222 {{code language="yml" theme="RDark" title="Get specific Term Response" collapse="true"}} 9223 9223 { ... ... @@ -9271,13 +9271,13 @@ 9271 9271 9272 9272 (% style="color: rgb(107,107,107);" %)Request 9273 9273 9274 -{{code language="php" theme="RDark" title="Lookup Term Request" collapse="true"}}9416 +{{code language="php" theme="RDark" title="Lookup Term Request"}} 9275 9275 <?php 9276 9276 9277 9277 $curl = curl_init(); 9278 9278 9279 9279 curl_setopt_array($curl, array( 9280 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/terms/lookup?Name={{Term Name}}9422 + CURLOPT_URL => 'https://api.onecount.net/v2/terms/lookup?Name={{Term Name}}', 9281 9281 CURLOPT_RETURNTRANSFER => true, 9282 9282 CURLOPT_ENCODING => '', 9283 9283 CURLOPT_MAXREDIRS => 10, ... ... @@ -9298,22 +9298,201 @@ 9298 9298 9299 9299 \\ 9300 9300 9301 -(% style="color: rgb(107,107,107);" %)Response 9443 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9302 9302 9303 -{{code language="yml" theme="RDark" title="Lookup Term Response" collapse="true"/}} 9445 +{{code language="yml" theme="RDark" title="Lookup Term Response" collapse="true"}} 9446 +{ 9447 + "result": { 9448 + "success": "1", 9449 + "error": { 9450 + "code": "", 9451 + "message": "" 9452 + } 9453 + }, 9454 + "Terms": [ 9455 + { 9456 + "Id": 431, 9457 + "Name": "Test term for API 1", 9458 + "Description": null, 9459 + "Duration": 0, 9460 + "DurationUnit": "", 9461 + "Price": "0.00", 9462 + "ProductId": 599 9463 + } 9464 + ] 9465 +} 9466 +{{/code}} 9304 9304 9305 9305 \\ 9306 9306 9470 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 9471 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Create Term(%%) == 9472 + 9473 +---- 9474 + 9475 +{{panel bgColor="#D3D3D3" width="100%"}} 9476 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/terms 9477 +{{/panel}} 9478 + 9479 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 9480 + 9481 +---- 9482 + 9483 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 9484 + 9485 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 9486 + 9487 +---- 9488 + 9489 +{{code language="yml" theme="RDark" title="Body"}} 9490 +{"Name":"Test API term creation","Description":"Test API term creation","Duration":10,"ProductId":599} 9491 +{{/code}} 9492 + 9493 +==== Example ==== 9494 + 9495 +---- 9496 + 9497 +(% style="color: rgb(107,107,107);" %)Request 9498 + 9499 +{{code language="php" theme="RDark" title="Create Term Request"}} 9500 +<?php 9501 + 9502 +$curl = curl_init(); 9503 + 9504 +curl_setopt_array($curl, array( 9505 + CURLOPT_URL => 'https://api.onecount.net/v2/terms', 9506 + CURLOPT_RETURNTRANSFER => true, 9507 + CURLOPT_ENCODING => '', 9508 + CURLOPT_MAXREDIRS => 10, 9509 + CURLOPT_TIMEOUT => 0, 9510 + CURLOPT_FOLLOWLOCATION => true, 9511 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 9512 + CURLOPT_CUSTOMREQUEST => 'POST', 9513 + CURLOPT_POSTFIELDS =>'{"Name":"Test API term creation","Description":"Test API term creation","Duration":10,"ProductId":599} 9514 + 9515 +', 9516 + CURLOPT_HTTPHEADER => array( 9517 + 'Appkey: {{ONECOUNT API KEY}}' 9518 + ), 9519 +)); 9520 + 9521 +$response = curl_exec($curl); 9522 + 9523 +curl_close($curl); 9524 +echo $response; 9525 + 9526 + 9527 +{{/code}} 9528 + 9307 9307 \\ 9308 9308 9531 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9532 + 9533 +{{code language="yml" theme="RDark" title="Create Term Response" collapse="true"}} 9534 +{ 9535 + "result": { 9536 + "success": "1", 9537 + "error": { 9538 + "code": "", 9539 + "message": "" 9540 + } 9541 + }, 9542 + "Terms": [ 9543 + { 9544 + "Id": 447 9545 + } 9546 + ] 9547 +} 9548 +{{/code}} 9549 + 9309 9309 \\ 9310 9310 9552 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 9553 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(0, 83, 184)" %)PUT (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %)Update Term(%%) == 9554 + 9555 +---- 9556 + 9557 +{{panel bgColor="#D3D3D3" width="100%"}} 9558 + (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/terms/~{~{Term Id}} 9559 +{{/panel}} 9560 + 9561 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 9562 + 9563 +---- 9564 + 9565 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 9566 + 9567 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 9568 + 9569 +---- 9570 + 9571 +{{code language="yml" theme="RDark" title="Body"}} 9572 +{"Name":"Test API term creation update","Description":"Test API term creation update","Duration":10,"ProductId":599} 9573 +{{/code}} 9574 + 9575 +==== Example ==== 9576 + 9577 +---- 9578 + 9579 +(% style="color: rgb(107,107,107);" %)Request 9580 + 9581 +{{code language="php" theme="RDark" title="Update Term Request"}} 9582 + <?php 9583 + 9584 +$curl = curl_init(); 9585 + 9586 +curl_setopt_array($curl, array( 9587 + CURLOPT_URL => 'https://api.onecount.net/v2/terms/{{Term Id}}', 9588 + CURLOPT_RETURNTRANSFER => true, 9589 + CURLOPT_ENCODING => '', 9590 + CURLOPT_MAXREDIRS => 10, 9591 + CURLOPT_TIMEOUT => 0, 9592 + CURLOPT_FOLLOWLOCATION => true, 9593 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 9594 + CURLOPT_CUSTOMREQUEST => 'PUT', 9595 + CURLOPT_POSTFIELDS =>'{"Name":"Test API term creation update","Description":"Test API term creation update","Duration":10,"ProductId":599}', 9596 + CURLOPT_HTTPHEADER => array( 9597 + 'Appkey: {{ONECOUNT API KEY}}' 9598 + ), 9599 +)); 9600 + 9601 +$response = curl_exec($curl); 9602 + 9603 +curl_close($curl); 9604 +echo $response; 9605 +{{/code}} 9606 + 9311 9311 \\ 9312 9312 9609 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9610 + 9611 +{{code language="yml" theme="RDark" title="Update Term Response" collapse="true"}} 9612 + { 9613 + "result": { 9614 + "success": "1", 9615 + "error": { 9616 + "code": "", 9617 + "message": "" 9618 + } 9619 + }, 9620 + "Terms": [ 9621 + { 9622 + "Id": 447, 9623 + "Name": "Test API term creation update", 9624 + "Description": "Test API term creation update", 9625 + "Duration": 10, 9626 + "DurationUnit": "", 9627 + "Price": "0.00", 9628 + "ProductId": 599 9629 + } 9630 + ] 9631 +} 9632 +{{/code}} 9633 + 9313 9313 \\ 9314 9314 9315 9315 (% class="western" %) 9316 -**COMPONENT: Resources** 9637 +=== **COMPONENT: Resources** === 9317 9317 9318 9318 (% class="western" %) 9319 9319 Resources are the available entities that can be accessed/modified via API. Each resource can be created, updated or requested by using the corresponding http method described above. ... ... @@ -9445,13 +9445,13 @@ 9445 9445 9446 9446 (% style="color: rgb(107,107,107);" %)Request 9447 9447 9448 -{{code language="php" theme="RDark" title="Get All Resource Request" collapse="true"}}9769 +{{code language="php" theme="RDark" title="Get All Resource Request"}} 9449 9449 <?php 9450 9450 9451 9451 $curl = curl_init(); 9452 9452 9453 9453 curl_setopt_array($curl, array( 9454 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/resources?limit=10',9775 + CURLOPT_URL => 'https://api.onecount.net/v2/resources', 9455 9455 CURLOPT_RETURNTRANSFER => true, 9456 9456 CURLOPT_ENCODING => '', 9457 9457 CURLOPT_MAXREDIRS => 10, ... ... @@ -9472,7 +9472,7 @@ 9472 9472 9473 9473 \\ 9474 9474 9475 -(% style="color: rgb(107,107,107);" %)Response 9796 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9476 9476 9477 9477 {{code language="yml" theme="RDark" title="Get All Resource Response" collapse="true"}} 9478 9478 { ... ... @@ -9591,13 +9591,13 @@ 9591 9591 9592 9592 (% style="color: rgb(107,107,107);" %)Request 9593 9593 9594 -{{code language="php" theme="RDark" title="Get specific Resource Request" collapse="true"}}9915 +{{code language="php" theme="RDark" title="Get specific Resource Request"}} 9595 9595 <?php 9596 9596 9597 9597 $curl = curl_init(); 9598 9598 9599 9599 curl_setopt_array($curl, array( 9600 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/resources/{{Resource ID}}',9921 + CURLOPT_URL => 'https://api.onecount.net/v2/resources/{{Resource ID}}', 9601 9601 CURLOPT_RETURNTRANSFER => true, 9602 9602 CURLOPT_ENCODING => '', 9603 9603 CURLOPT_MAXREDIRS => 10, ... ... @@ -9618,7 +9618,7 @@ 9618 9618 9619 9619 \\ 9620 9620 9621 -(% style="color: rgb(107,107,107);" %)Response 9942 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9622 9622 9623 9623 {{code language="yml" theme="RDark" title="Get specific Resource Response" collapse="true"}} 9624 9624 { ... ... @@ -9650,7 +9650,7 @@ 9650 9650 ---- 9651 9651 9652 9652 {{panel bgColor="#D3D3D3" width="100%"}} 9653 -(% class="nolink" %) [[https:~~/~~/api.onecount.net/v2/users>>url:https://api.onecount.net/v2/users||shape="rect"]](% style="color: rgb(33,33,33);" %)/lookup?2=user_242_6298&return=1,2,3,49974 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources/lookup?Name={(%%){Resource Name}} 9654 9654 {{/panel}} 9655 9655 9656 9656 === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === ... ... @@ -9663,8 +9663,7 @@ 9663 9663 9664 9664 ---- 9665 9665 9666 -(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)2 (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)user_242_6298(%%) 9667 -(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)return (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)1,2,3,4 9987 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Name (% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key nolink" style="color: rgb(33, 33, 33); color: rgb(33, 33, 33)" %){(% style="color: rgb(33,33,33);" class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key nolink" %){Resource Name}} 9668 9668 9669 9669 ==== Example ==== 9670 9670 ... ... @@ -9672,30 +9672,237 @@ 9672 9672 9673 9673 (% style="color: rgb(107,107,107);" %)Request 9674 9674 9675 -{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}} 9995 +{{code language="php" theme="RDark" title="Lookup Resource Request"}} 9996 + <?php 9676 9676 9677 - \\9998 +$curl = curl_init(); 9678 9678 9679 -(% style="color: rgb(107,107,107);" %)Response 200 OK 10000 +curl_setopt_array($curl, array( 10001 + CURLOPT_URL => 'https://api.onecount.net/v2/resources/lookup?Name={{Resource Name}}', 10002 + CURLOPT_RETURNTRANSFER => true, 10003 + CURLOPT_ENCODING => '', 10004 + CURLOPT_MAXREDIRS => 10, 10005 + CURLOPT_TIMEOUT => 0, 10006 + CURLOPT_FOLLOWLOCATION => true, 10007 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10008 + CURLOPT_CUSTOMREQUEST => 'GET', 10009 + CURLOPT_HTTPHEADER => array( 10010 + 'Appkey: {{ONECOUNT API KEY}}' 10011 + ), 10012 +)); 9680 9680 9681 - {{code language="yml" theme="RDark" title="Lookup user Response"collapse="true"/}}10014 +$response = curl_exec($curl); 9682 9682 10016 +curl_close($curl); 10017 +echo $response; 10018 +{{/code}} 10019 + 9683 9683 \\ 9684 9684 10022 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10023 + 10024 +{{code language="yml" theme="RDark" title="Lookup Resource Response" collapse="true"}} 10025 + { 10026 + "result": { 10027 + "success": "1", 10028 + "error": { 10029 + "code": "", 10030 + "message": "" 10031 + } 10032 + }, 10033 + "Resources": [ 10034 + { 10035 + "Id": 479, 10036 + "Name": "Virtualization Review", 10037 + "Description": "", 10038 + "Type": "0", 10039 + "Value": "", 10040 + "FreePass": 0 10041 + } 10042 + ] 10043 +} 10044 +{{/code}} 10045 + 9685 9685 \\ 9686 9686 10048 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 10049 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Create Resource(%%) == 10050 + 10051 +---- 10052 + 10053 +{{panel bgColor="#D3D3D3" width="100%"}} 10054 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources 10055 +{{/panel}} 10056 + 10057 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 10058 + 10059 +---- 10060 + 10061 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 10062 + 10063 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 10064 + 10065 +---- 10066 + 10067 +{{code language="yml" theme="RDark" title="Body"}} 10068 +{"Name":"Test API product creation 22","Description":"Test API product creation 22","Type":3,"FreePass":1,"Value":["http://one-count.com"],"Gating":false,"Price":0,"PrimaryFormId":"","VendorId":1} 10069 +{{/code}} 10070 + 10071 +==== Example ==== 10072 + 10073 +---- 10074 + 10075 +(% style="color: rgb(107,107,107);" %)Request 10076 + 10077 +{{code language="php" theme="RDark" title="Create Resource Request"}} 10078 + <?php 10079 + 10080 +$curl = curl_init(); 10081 + 10082 +curl_setopt_array($curl, array( 10083 + CURLOPT_URL => 'https://api.onecount.net/v2/resources', 10084 + CURLOPT_RETURNTRANSFER => true, 10085 + CURLOPT_ENCODING => '', 10086 + CURLOPT_MAXREDIRS => 10, 10087 + CURLOPT_TIMEOUT => 0, 10088 + CURLOPT_FOLLOWLOCATION => true, 10089 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10090 + CURLOPT_CUSTOMREQUEST => 'POST', 10091 + CURLOPT_POSTFIELDS =>'{"Name":"Test API product creation 21","Description":"Test API product creation 21","Type":3,"FreePass":1,"Value":["http://one-count.com"],"Gating":false,"Price":0,"PrimaryFormId":"","VendorId":1}', 10092 + CURLOPT_HTTPHEADER => array( 10093 + 'Appkey: {{ONECOUNT API KEY}}' 10094 + ), 10095 +)); 10096 + 10097 +$response = curl_exec($curl); 10098 + 10099 +curl_close($curl); 10100 +echo $response; 10101 +{{/code}} 10102 + 9687 9687 \\ 9688 9688 10105 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10106 + 10107 +{{code language="yml" theme="RDark" title="Create Resource Response" collapse="true"}} 10108 + { 10109 + "result": { 10110 + "success": "1", 10111 + "error": { 10112 + "code": "", 10113 + "message": "" 10114 + } 10115 + }, 10116 + "Resources": [ 10117 + { 10118 + "Id": 871, 10119 + "Name": "Test API product creation 21", 10120 + "Description": "Test API product creation 21", 10121 + "Type": "3", 10122 + "Value": "http://one-count.com", 10123 + "FreePass": 1 10124 + } 10125 + ] 10126 +} 10127 +{{/code}} 10128 + 9689 9689 \\ 9690 9690 10131 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 10132 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(0, 83, 184)" %)PUT (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %)Update Resource(%%) == 10133 + 10134 +---- 10135 + 10136 +{{panel bgColor="#D3D3D3" width="100%"}} 10137 + (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources/~{~{resource id}} 10138 +{{/panel}} 10139 + 10140 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 10141 + 10142 +---- 10143 + 10144 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 10145 + 10146 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 10147 + 10148 +---- 10149 + 10150 +{{code language="yml" theme="RDark" title="Body"}} 10151 +{"Name":"Test API product creation 23","Description":"Test API product creation 23","Type":3,"FreePass":1,"Value":["http://one-count.com","onecount.net"],"Gating":false,"Price":0,"PrimaryFormId":"","VendorId":1} 10152 +{{/code}} 10153 + 10154 +==== Example ==== 10155 + 10156 +---- 10157 + 10158 +(% style="color: rgb(107,107,107);" %)Request 10159 + 10160 +{{code language="php" theme="RDark" title="Update Resource Request"}} 10161 + <?php 10162 + 10163 +$curl = curl_init(); 10164 + 10165 +curl_setopt_array($curl, array( 10166 + CURLOPT_URL => 'https://api.onecount.net/v2/resources/{{resource id}}', 10167 + CURLOPT_RETURNTRANSFER => true, 10168 + CURLOPT_ENCODING => '', 10169 + CURLOPT_MAXREDIRS => 10, 10170 + CURLOPT_TIMEOUT => 0, 10171 + CURLOPT_FOLLOWLOCATION => true, 10172 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10173 + CURLOPT_CUSTOMREQUEST => 'PUT', 10174 + CURLOPT_POSTFIELDS =>'{"Name":"Test API product creation 23","Description":"Test API product creation 23","Type":3,"FreePass":1,"Value":["http://one-count.com","onecount.net"],"Gating":false,"Price":0,"PrimaryFormId":"","VendorId":1}', 10175 + CURLOPT_HTTPHEADER => array( 10176 + 'Appkey: {{ONECOUNT API KEY}}' 10177 + ), 10178 +)); 10179 + 10180 +$response = curl_exec($curl); 10181 + 10182 +curl_close($curl); 10183 +echo $response; 10184 +{{/code}} 10185 + 9691 9691 \\ 9692 9692 10188 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10189 + 10190 +{{code language="yml" theme="RDark" title="Update Resource Response" collapse="true"}} 10191 + { 10192 + "result": { 10193 + "success": "1", 10194 + "error": { 10195 + "code": "", 10196 + "message": "" 10197 + } 10198 + }, 10199 + "Resources": [ 10200 + { 10201 + "Id": 903, 10202 + "Name": "Test API product creation 23", 10203 + "Description": "Test API product creation 23", 10204 + "Type": "3", 10205 + "Value": "http://one-count.com", 10206 + "FreePass": 1 10207 + }, 10208 + { 10209 + "Id": 903, 10210 + "Name": "Test API product creation 23", 10211 + "Description": "Test API product creation 23", 10212 + "Type": "3", 10213 + "Value": "onecount.net", 10214 + "FreePass": 1 10215 + } 10216 + ] 10217 +} 10218 +{{/code}} 10219 + 9693 9693 (% class="western" %) 9694 9694 \\ 9695 9695 9696 9696 (% class="western" %) 9697 -**COMPONENT: Source Codes 9698 -** 10224 +=== **COMPONENT: Source Codes 10225 +** === 9699 9699 9700 9700 (% class="western" %) 9701 9701 This resource is for manipulating source code for a resource. A source code can be created, updated or searched. ... ... @@ -9792,13 +9792,13 @@ 9792 9792 9793 9793 (% style="color: rgb(107,107,107);" %)Request 9794 9794 9795 -{{code language="php" theme="RDark" title="Get All Source code Request" collapse="true"}}10322 +{{code language="php" theme="RDark" title="Get All Source code Request"}} 9796 9796 <?php 9797 9797 9798 9798 $curl = curl_init(); 9799 9799 9800 9800 curl_setopt_array($curl, array( 9801 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/sources',10328 + CURLOPT_URL => 'https://api.onecount.net/v2/sources', 9802 9802 CURLOPT_RETURNTRANSFER => true, 9803 9803 CURLOPT_ENCODING => '', 9804 9804 CURLOPT_MAXREDIRS => 10, ... ... @@ -9819,7 +9819,7 @@ 9819 9819 9820 9820 \\ 9821 9821 9822 -(% style="color: rgb(107,107,107);" %)Response 10349 +(% style="color: rgb(107,107,107);" %)Response 200 OK 9823 9823 9824 9824 {{code language="yml" theme="RDark" title="Get All Source code Response" collapse="true"}} 9825 9825 { ... ... @@ -10008,13 +10008,13 @@ 10008 10008 10009 10009 (% style="color: rgb(107,107,107);" %)Request 10010 10010 10011 -{{code language="php" theme="RDark" title="Get specific Source Request" collapse="true"}}10538 +{{code language="php" theme="RDark" title="Get specific Source Request"}} 10012 10012 <?php 10013 10013 10014 10014 $curl = curl_init(); 10015 10015 10016 10016 curl_setopt_array($curl, array( 10017 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/sources/{{source code id}}',10544 + CURLOPT_URL => 'https://api.onecount.net/v2/sources/{{source code id}}', 10018 10018 CURLOPT_RETURNTRANSFER => true, 10019 10019 CURLOPT_ENCODING => '', 10020 10020 CURLOPT_MAXREDIRS => 10, ... ... @@ -10035,7 +10035,7 @@ 10035 10035 10036 10036 \\ 10037 10037 10038 -(% style="color: rgb(107,107,107);" %)Response 10565 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10039 10039 10040 10040 {{code language="yml" theme="RDark" title="Get specific Source Response" collapse="true"}} 10041 10041 { ... ... @@ -10065,7 +10065,7 @@ 10065 10065 ---- 10066 10066 10067 10067 {{panel bgColor="#D3D3D3" width="100%"}} 10068 -(% class="nolink" %) [[https:~~/~~/api.onecount.net/v2/users>>url:https://api.onecount.net/v2/users||shape="rect"]](% style="color: rgb(33,33,33);" %)/lookup?2=user_242_6298&return=1,2,3,410595 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/sources/lookup?Source={(%%){Source code Name}} 10069 10069 {{/panel}} 10070 10070 10071 10071 === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === ... ... @@ -10078,8 +10078,7 @@ 10078 10078 10079 10079 ---- 10080 10080 10081 -(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)2 (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)user_242_6298(%%) 10082 -(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)return (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)1,2,3,4 10608 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Source (% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key nolink" style="color: rgb(33, 33, 33); color: rgb(33, 33, 33)" %){(% style="color: rgb(33,33,33);" class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key nolink" %){Source code Name}} 10083 10083 10084 10084 ==== Example ==== 10085 10085 ... ... @@ -10087,27 +10087,222 @@ 10087 10087 10088 10088 (% style="color: rgb(107,107,107);" %)Request 10089 10089 10090 -{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}} 10616 +{{code language="php" theme="RDark" title="Lookup Source code Request"}} 10617 + <?php 10091 10091 10619 +$curl = curl_init(); 10620 + 10621 +curl_setopt_array($curl, array( 10622 + CURLOPT_URL => 'https://api.onecount.net/v2/sources/lookup?Source={{Source code Name}}', 10623 + CURLOPT_RETURNTRANSFER => true, 10624 + CURLOPT_ENCODING => '', 10625 + CURLOPT_MAXREDIRS => 10, 10626 + CURLOPT_TIMEOUT => 0, 10627 + CURLOPT_FOLLOWLOCATION => true, 10628 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10629 + CURLOPT_CUSTOMREQUEST => 'GET', 10630 + CURLOPT_HTTPHEADER => array( 10631 + 'Appkey: {{ONECOUNT API KEY}}' 10632 + ), 10633 +)); 10634 + 10635 +$response = curl_exec($curl); 10636 + 10637 +curl_close($curl); 10638 +echo $response; 10639 +{{/code}} 10640 + 10092 10092 \\ 10093 10093 10094 -(% style="color: rgb(107,107,107);" %)Response 10643 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10095 10095 10096 -{{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"/}} 10645 +{{code language="yml" theme="RDark" title="Lookup Source code Response" collapse="true"}} 10646 + { 10647 + "result": { 10648 + "success": "1", 10649 + "error": { 10650 + "code": "", 10651 + "message": "" 10652 + } 10653 + }, 10654 + "Sources": [ 10655 + { 10656 + "Id": 26, 10657 + "Source": "GCN-Member", 10658 + "Description": "Uploaded from Reston VA", 10659 + "Parent": 0 10660 + } 10661 + ] 10662 +} 10663 +{{/code}} 10097 10097 10098 10098 \\ 10099 10099 10667 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 10668 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Create Source code(%%) == 10669 + 10670 +---- 10671 + 10672 +{{panel bgColor="#D3D3D3" width="100%"}} 10673 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/sources 10674 +{{/panel}} 10675 + 10676 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 10677 + 10678 +---- 10679 + 10680 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 10681 + 10682 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 10683 + 10684 +---- 10685 + 10686 +{{code language="yml" theme="RDark" title="Body"}} 10687 +{"Source":"Test source code from API"} 10688 +{{/code}} 10689 + 10690 +==== Example ==== 10691 + 10692 +---- 10693 + 10694 +(% style="color: rgb(107,107,107);" %)Request 10695 + 10696 +{{code language="php" theme="RDark" title="Create Source code Request"}} 10697 + <?php 10698 + 10699 +$curl = curl_init(); 10700 + 10701 +curl_setopt_array($curl, array( 10702 + CURLOPT_URL => 'https://api.onecount.net/v2/sources', 10703 + CURLOPT_RETURNTRANSFER => true, 10704 + CURLOPT_ENCODING => '', 10705 + CURLOPT_MAXREDIRS => 10, 10706 + CURLOPT_TIMEOUT => 0, 10707 + CURLOPT_FOLLOWLOCATION => true, 10708 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10709 + CURLOPT_CUSTOMREQUEST => 'POST', 10710 + CURLOPT_POSTFIELDS =>'{"Source":"Test source code from API"}', 10711 + CURLOPT_HTTPHEADER => array( 10712 + 'Appkey: {{ONECOUNT API KEY}}' 10713 + ), 10714 +)); 10715 + 10716 +$response = curl_exec($curl); 10717 + 10718 +curl_close($curl); 10719 +echo $response; 10720 +{{/code}} 10721 + 10100 10100 \\ 10101 10101 10724 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10725 + 10726 +{{code language="yml" theme="RDark" title="Create Source code Response" collapse="true"}} 10727 + { 10728 + "result": { 10729 + "success": "1", 10730 + "error": { 10731 + "code": "", 10732 + "message": "" 10733 + } 10734 + }, 10735 + "Sources": [ 10736 + { 10737 + "Id": 223, 10738 + "Source": "Test source code from API", 10739 + "Description": "", 10740 + "Parent": 0 10741 + } 10742 + ] 10743 +} 10744 +{{/code}} 10745 + 10102 10102 \\ 10103 10103 10748 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 10749 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(0, 83, 184)" %)PUT (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %)Update Source code(%%) == 10750 + 10751 +---- 10752 + 10753 +{{panel bgColor="#D3D3D3" width="100%"}} 10754 + (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/sources/~{~{source code id}} 10755 +{{/panel}} 10756 + 10757 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 10758 + 10759 +---- 10760 + 10761 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 10762 + 10763 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 10764 + 10765 +---- 10766 + 10767 +{{code language="yml" theme="RDark" title="Body"}} 10768 +{"Source":"Test API","Parent":215} 10769 +{{/code}} 10770 + 10771 +==== Example ==== 10772 + 10773 +---- 10774 + 10775 +(% style="color: rgb(107,107,107);" %)Request 10776 + 10777 +{{code language="php" theme="RDark" title="Update Source code Request"}} 10778 + <?php 10779 + 10780 +$curl = curl_init(); 10781 + 10782 +curl_setopt_array($curl, array( 10783 + CURLOPT_URL => 'https://api.onecount.net/v2/sources/{{source code id}}', 10784 + CURLOPT_RETURNTRANSFER => true, 10785 + CURLOPT_ENCODING => '', 10786 + CURLOPT_MAXREDIRS => 10, 10787 + CURLOPT_TIMEOUT => 0, 10788 + CURLOPT_FOLLOWLOCATION => true, 10789 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10790 + CURLOPT_CUSTOMREQUEST => 'PUT', 10791 + CURLOPT_POSTFIELDS =>'{"Source":"Test API","Parent":215}', 10792 + CURLOPT_HTTPHEADER => array( 10793 + 'Appkey: {{ONECOUNT API KEY}}' 10794 + ), 10795 +)); 10796 + 10797 +$response = curl_exec($curl); 10798 + 10799 +curl_close($curl); 10800 +echo $response; 10801 +{{/code}} 10802 + 10104 10104 \\ 10105 10105 10805 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10806 + 10807 +{{code language="yml" theme="RDark" title="Update Source code Response" collapse="true"}} 10808 + { 10809 + "result": { 10810 + "success": "1", 10811 + "error": { 10812 + "code": "", 10813 + "message": "" 10814 + } 10815 + }, 10816 + "Sources": [ 10817 + { 10818 + "Id": 223, 10819 + "Source": "Test API", 10820 + "Description": "", 10821 + "Parent": 215 10822 + } 10823 + ] 10824 +} 10825 +{{/code}} 10826 + 10106 10106 (% class="western" %) 10107 10107 \\ 10108 10108 10109 10109 (% class="western" %) 10110 -**COMPONENT: Transactions** 10831 +=== **COMPONENT: Transactions** === 10111 10111 10112 10112 (% class="western" %) 10113 10113 This resource is for manipulating transactions resource. A transaction can be created or searched. ... ... @@ -10191,13 +10191,13 @@ 10191 10191 10192 10192 (% style="color: rgb(107,107,107);" %)Request 10193 10193 10194 -{{code language="php" theme="RDark" title="Get All Transaction Request" collapse="true"}}10915 +{{code language="php" theme="RDark" title="Get All Transaction Request"}} 10195 10195 <?php 10196 10196 10197 10197 $curl = curl_init(); 10198 10198 10199 10199 curl_setopt_array($curl, array( 10200 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/transactions?limit=100',10921 + CURLOPT_URL => 'https://api.onecount.net/v2/transactions', 10201 10201 CURLOPT_RETURNTRANSFER => true, 10202 10202 CURLOPT_ENCODING => '', 10203 10203 CURLOPT_MAXREDIRS => 10, ... ... @@ -10218,7 +10218,7 @@ 10218 10218 10219 10219 \\ 10220 10220 10221 -(% style="color: rgb(107,107,107);" %)Response 10942 +(% style="color: rgb(107,107,107);" %)Response 200 OK 10222 10222 10223 10223 {{code language="yml" theme="RDark" title="Get All Transaction Response" collapse="true"}} 10224 10224 { ... ... @@ -11757,13 +11757,13 @@ 11757 11757 11758 11758 (% style="color: rgb(107,107,107);" %)Request 11759 11759 11760 -{{code language="php" theme="RDark" title="Get specific Transaction Request" collapse="true"}}12481 +{{code language="php" theme="RDark" title="Get specific Transaction Request"}} 11761 11761 <?php 11762 11762 11763 11763 $curl = curl_init(); 11764 11764 11765 11765 curl_setopt_array($curl, array( 11766 - CURLOPT_URL => ' rayaan.onecount.net/api/v2/transactions/{{Transaction id}}',12487 + CURLOPT_URL => 'https://api.onecount.net/v2/transactions/{{Transaction id}}', 11767 11767 CURLOPT_RETURNTRANSFER => true, 11768 11768 CURLOPT_ENCODING => '', 11769 11769 CURLOPT_MAXREDIRS => 10, ... ... @@ -11784,7 +11784,7 @@ 11784 11784 11785 11785 \\ 11786 11786 11787 -(% style="color: rgb(107,107,107);" %)Response 12508 +(% style="color: rgb(107,107,107);" %)Response 200 OK 11788 11788 11789 11789 {{code language="yml" theme="RDark" title="Get specific Transaction Response" collapse="true"}} 11790 11790 { ... ... @@ -11823,7 +11823,7 @@ 11823 11823 ---- 11824 11824 11825 11825 {{panel bgColor="#D3D3D3" width="100%"}} 11826 -(% class="nolink" %) [[https:~~/~~/api.onecount.net/v2/users>>url:https://api.onecount.net/v2/users||shape="rect"]](% style="color: rgb(33,33,33);" %)/lookup?2=user_242_6298&return=1,2,3,412547 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/transactions/lookup?UserId=~{~{OCID}} 11827 11827 {{/panel}} 11828 11828 11829 11829 === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === ... ... @@ -11836,8 +11836,7 @@ 11836 11836 11837 11837 ---- 11838 11838 11839 -(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)2 (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)user_242_6298(%%) 11840 -(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)return (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)1,2,3,4 12560 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)UserId (% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key nolink" style="color: rgb(33, 33, 33); color: rgb(33, 33, 33)" %)~{~{OCID}} 11841 11841 11842 11842 ==== Example ==== 11843 11843 ... ... @@ -11845,65 +11845,1040 @@ 11845 11845 11846 11846 (% style="color: rgb(107,107,107);" %)Request 11847 11847 11848 -{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}} 12568 +{{code language="php" theme="RDark" title="Lookup Transaction Request"}} 12569 + <?php 11849 11849 11850 - \\12571 +$curl = curl_init(); 11851 11851 11852 -(% style="color: rgb(107,107,107);" %)Response 200 OK 12573 +curl_setopt_array($curl, array( 12574 + CURLOPT_URL => 'https://api.onecount.net/v2/transactions/lookup?UserId={{OCID}}', 12575 + CURLOPT_RETURNTRANSFER => true, 12576 + CURLOPT_ENCODING => '', 12577 + CURLOPT_MAXREDIRS => 10, 12578 + CURLOPT_TIMEOUT => 0, 12579 + CURLOPT_FOLLOWLOCATION => true, 12580 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 12581 + CURLOPT_CUSTOMREQUEST => 'GET', 12582 + CURLOPT_HTTPHEADER => array( 12583 + 'Appkey: {{ONECOUNT API KEY}}' 12584 + ), 12585 +)); 11853 11853 11854 - {{code language="yml" theme="RDark" title="Lookup user Response"collapse="true"/}}12587 +$response = curl_exec($curl); 11855 11855 11856 -\\ 12589 +curl_close($curl); 12590 +echo $response; 12591 +{{/code}} 11857 11857 11858 11858 \\ 11859 11859 11860 - \\12595 +(% style="color: rgb(107,107,107);" %)Response 200 OK 11861 11861 11862 -\\ 12597 +{{code language="yml" theme="RDark" title="Lookup Transaction Response" collapse="true"}} 12598 + { 12599 + "result": { 12600 + "success": "1", 12601 + "error": { 12602 + "code": "", 12603 + "message": "" 12604 + } 12605 + }, 12606 + "Transactions": [ 12607 + { 12608 + "Id": 52494786, 12609 + "UserId": 1234, 12610 + "TermId": 34, 12611 + "TransactionDate": "2016-01-19", 12612 + "TransactionTime": "15:30:04", 12613 + "RequestDate": "2016-01-19", 12614 + "UserIP": "12.226.247.2", 12615 + "SubscriptionType": "u", 12616 + "ProductId": 34, 12617 + "Source": 0, 12618 + "ProductStatus": 0, 12619 + "MediaFilePath": "", 12620 + "Amount": "" 12621 + }, 12622 + { 12623 + "Id": 42654041, 12624 + "UserId": 1234, 12625 + "TermId": 34, 12626 + "TransactionDate": "2015-09-09", 12627 + "TransactionTime": "11:20:39", 12628 + "RequestDate": "2015-09-09", 12629 + "UserIP": "24.187.236.98", 12630 + "SubscriptionType": "n", 12631 + "ProductId": 34, 12632 + "Source": 0, 12633 + "ProductStatus": 2, 12634 + "MediaFilePath": "", 12635 + "Amount": "" 12636 + }, 12637 + { 12638 + "Id": 97251022, 12639 + "UserId": 1234, 12640 + "TermId": 34, 12641 + "TransactionDate": "2015-06-04", 12642 + "TransactionTime": "14:59:42", 12643 + "RequestDate": "2015-06-04", 12644 + "UserIP": "12.226.247.2", 12645 + "SubscriptionType": "u", 12646 + "ProductId": 34, 12647 + "Source": 0, 12648 + "ProductStatus": 0, 12649 + "MediaFilePath": "", 12650 + "Amount": "" 12651 + }, 12652 + { 12653 + "Id": 55492559, 12654 + "UserId": 1234, 12655 + "TermId": 34, 12656 + "TransactionDate": "2015-04-03", 12657 + "TransactionTime": "16:32:04", 12658 + "RequestDate": "2015-04-03", 12659 + "UserIP": "24.187.236.98", 12660 + "SubscriptionType": "r", 12661 + "ProductId": 34, 12662 + "Source": 58, 12663 + "ProductStatus": 106, 12664 + "MediaFilePath": "", 12665 + "Amount": "" 12666 + }, 12667 + { 12668 + "Id": 98173391, 12669 + "UserId": 1234, 12670 + "TermId": 34, 12671 + "TransactionDate": "2015-04-03", 12672 + "TransactionTime": "15:50:45", 12673 + "RequestDate": "2014-08-19", 12674 + "UserIP": "24.187.236.98", 12675 + "SubscriptionType": "n", 12676 + "ProductId": 34, 12677 + "Source": 34, 12678 + "ProductStatus": 106, 12679 + "MediaFilePath": "", 12680 + "Amount": "" 12681 + }, 12682 + { 12683 + "Id": 91711793, 12684 + "UserId": 1234, 12685 + "TermId": 18, 12686 + "TransactionDate": "2015-04-27", 12687 + "TransactionTime": "14:24:51", 12688 + "RequestDate": "2015-04-27", 12689 + "UserIP": "24.187.236.98", 12690 + "SubscriptionType": "u", 12691 + "ProductId": 18, 12692 + "Source": 0, 12693 + "ProductStatus": 106, 12694 + "MediaFilePath": "", 12695 + "Amount": "" 12696 + }, 12697 + { 12698 + "Id": 74936400, 12699 + "UserId": 1234, 12700 + "TermId": 18, 12701 + "TransactionDate": "2015-04-27", 12702 + "TransactionTime": "12:35:18", 12703 + "RequestDate": "2015-04-27", 12704 + "UserIP": "68.196.187.74", 12705 + "SubscriptionType": "n", 12706 + "ProductId": 18, 12707 + "Source": 34, 12708 + "ProductStatus": 106, 12709 + "MediaFilePath": "", 12710 + "Amount": "" 12711 + }, 12712 + { 12713 + "Id": 21664714, 12714 + "UserId": 1234, 12715 + "TermId": 18, 12716 + "TransactionDate": "2015-04-03", 12717 + "TransactionTime": "15:50:46", 12718 + "RequestDate": "2015-04-03", 12719 + "UserIP": "24.187.236.98", 12720 + "SubscriptionType": "u", 12721 + "ProductId": 18, 12722 + "Source": 0, 12723 + "ProductStatus": 2, 12724 + "MediaFilePath": "", 12725 + "Amount": "" 12726 + }, 12727 + { 12728 + "Id": 81129263, 12729 + "UserId": 1234, 12730 + "TermId": 18, 12731 + "TransactionDate": "2014-08-19", 12732 + "TransactionTime": "11:18:55", 12733 + "RequestDate": "2014-08-19", 12734 + "UserIP": "74.201.38.1", 12735 + "SubscriptionType": "n", 12736 + "ProductId": 18, 12737 + "Source": 34, 12738 + "ProductStatus": 2, 12739 + "MediaFilePath": "", 12740 + "Amount": "" 12741 + }, 12742 + { 12743 + "Id": 30461748, 12744 + "UserId": 1234, 12745 + "ResourceId": 459, 12746 + "TransactionDate": "2023-03-15", 12747 + "TransactionTime": "12:07:55", 12748 + "RequestDate": "2023-03-15", 12749 + "UserIP": "74.201.38.12", 12750 + "SubscriptionType": "n", 12751 + "SourceCode": 0, 12752 + "ProductStatus": 0, 12753 + "MediaFilePath": "", 12754 + "Amount": "" 12755 + }, 12756 + { 12757 + "Id": 25858253, 12758 + "UserId": 1234, 12759 + "ResourceId": 451, 12760 + "TransactionDate": "2023-03-15", 12761 + "TransactionTime": "11:45:19", 12762 + "RequestDate": "2023-03-15", 12763 + "UserIP": "74.201.38.12", 12764 + "SubscriptionType": "n", 12765 + "SourceCode": 0, 12766 + "ProductStatus": 0, 12767 + "MediaFilePath": "", 12768 + "Amount": "" 12769 + }, 12770 + { 12771 + "Id": 69453260, 12772 + "UserId": 1234, 12773 + "ResourceId": 411, 12774 + "TransactionDate": "2022-06-07", 12775 + "TransactionTime": "17:03:14", 12776 + "RequestDate": "2022-06-07", 12777 + "UserIP": "74.201.38.12", 12778 + "SubscriptionType": "n", 12779 + "SourceCode": 0, 12780 + "ProductStatus": 0, 12781 + "MediaFilePath": "", 12782 + "Amount": "" 12783 + }, 12784 + { 12785 + "Id": 51354425, 12786 + "UserId": 1234, 12787 + "ResourceId": 355, 12788 + "TransactionDate": "2020-04-06", 12789 + "TransactionTime": "12:24:08", 12790 + "RequestDate": "2020-04-06", 12791 + "UserIP": "74.201.38.12", 12792 + "SubscriptionType": "n", 12793 + "SourceCode": 0, 12794 + "ProductStatus": 0, 12795 + "MediaFilePath": "", 12796 + "Amount": "" 12797 + } 12798 + ] 12799 +} 12800 +{{/code}} 11863 11863 11864 11864 \\ 11865 11865 11866 -\\ 12804 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 12805 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Create Transaction(%%) == 11867 11867 11868 - \\12807 +---- 11869 11869 11870 -\\ 12809 +{{panel bgColor="#D3D3D3" width="100%"}} 12810 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/transactions 12811 +{{/panel}} 11871 11871 11872 - \\12813 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 11873 11873 11874 - \\12815 +---- 11875 11875 12817 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 12818 + 12819 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 12820 + 12821 +---- 12822 + 12823 +{{code language="yml" theme="RDark" title="Body"}} 12824 +{"UserId": 1845775,"TermId":447 ,"UserIP":"192.168.0.1" ,"SubscriptionType":"n" , "ProductId":599 ,"FormId": "8f93834c-adce-4dc7-acd0-f3a1e0f7c63f","Source": 83,"ProductStatus": 2,"Amount":"0.00" ,"PaypalTransId":"" , "MediaFilePath":"" ,"Remarks": "USER SUBSCRIBED","BatchId":"1234" ,"Quantity": 1, "ExpireDate":"20251211" } 12825 +{{/code}} 12826 + 12827 +==== Example ==== 12828 + 12829 +---- 12830 + 12831 +(% style="color: rgb(107,107,107);" %)Request 12832 + 12833 +{{code language="php" theme="RDark" title="Create Transaction Request"}} 12834 + <?php 12835 + 12836 +$curl = curl_init(); 12837 + 12838 +curl_setopt_array($curl, array( 12839 + CURLOPT_URL => 'https://api.onecount.net/v2/transactions', 12840 + CURLOPT_RETURNTRANSFER => true, 12841 + CURLOPT_ENCODING => '', 12842 + CURLOPT_MAXREDIRS => 10, 12843 + CURLOPT_TIMEOUT => 0, 12844 + CURLOPT_FOLLOWLOCATION => true, 12845 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 12846 + CURLOPT_CUSTOMREQUEST => 'POST', 12847 + CURLOPT_POSTFIELDS =>'{"UserId": 1845775,"TermId":447 ,"UserIP":"192.168.0.1" ,"SubscriptionType":"n" , "ProductId":599 ,"FormId": "8f93834c-adce-4dc7-acd0-f3a1e0f7c63f","Source": 83,"ProductStatus": 2,"Amount":"0.00" ,"PaypalTransId":"" , "MediaFilePath":"" ,"Remarks": "USER SUBSCRIBED","BatchId":"1234" ,"Quantity": 1, "ExpireDate":"20251211" }', 12848 + CURLOPT_HTTPHEADER => array( 12849 + 'Appkey: {{ONECOUNT API KEY}}' 12850 + ), 12851 +)); 12852 + 12853 +$response = curl_exec($curl); 12854 + 12855 +curl_close($curl); 12856 +echo $response; 12857 +{{/code}} 12858 + 11876 11876 \\ 11877 11877 12861 +(% style="color: rgb(107,107,107);" %)Response 200 OK 12862 + 12863 +{{code language="yml" theme="RDark" title="Create Transaction Response" collapse="true"}} 12864 + { 12865 + "result": { 12866 + "success": "1", 12867 + "error": { 12868 + "code": "", 12869 + "message": "" 12870 + } 12871 + }, 12872 + "Transactions": { 12873 + "Id": "1234", 12874 + "UserId": 1845775, 12875 + "TermId": 447, 12876 + "TransactionDate": "20231211", 12877 + "TransactionTime": "09:34:26", 12878 + "RequestDate": "20231211", 12879 + "UserIP": "192.168.0.1", 12880 + "SubscriptionType": "n", 12881 + "ProductId": 599, 12882 + "Source": 83, 12883 + "ProductStatus": 2, 12884 + "MediaFilePath": "", 12885 + "Amount": "0.00" 12886 + } 12887 +} 12888 +{{/code}} 12889 + 11878 11878 \\ 11879 11879 12892 +=== **COMPONENT: Engagements** === 12893 + 12894 +(% class="western" %) 12895 +Engagement can be added, updated and searched for using the engagements resource from the api. 12896 + 12897 +(% class="western" %) 11880 11880 \\ 11881 11881 12900 +(% class="wrapped" %) 12901 +(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12902 +((( 12903 +(% class="western" %) 12904 +**Method** 12905 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12906 +((( 12907 +(% class="western" %) 12908 +**Url** 12909 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12910 +((( 12911 +(% class="western" %) 12912 +**Action** 12913 +))) 12914 +(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12915 +((( 12916 +(% class="western" %) 12917 +GET 12918 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12919 +((( 12920 +(% class="western" %) 12921 +/(% style="color: rgb(33,33,33);" %)engagements 12922 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12923 +((( 12924 +(% class="western" %) 12925 +Get engagement data limiting 25. 12926 +))) 12927 +(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12928 +((( 12929 +(% class="western" %) 12930 +GET 12931 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12932 +((( 12933 +(% class="western" %) 12934 +/(% style="color: rgb(33,33,33);" %)engagements(%%)/<engagement id> 12935 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12936 +((( 12937 +(% class="western" %) 12938 +Get data for engagement id. The engagement id is a string 12939 +))) 12940 +(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12941 +((( 12942 +(% class="western" %) 12943 +POST 12944 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12945 +((( 12946 +(% class="western" %) 12947 +/(% style="color: rgb(33,33,33);" %)engagements 12948 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12949 +((( 12950 +(% class="western" %) 12951 +Create a new engagement 12952 + 12953 +(% class="western" %) 12954 +Parameters required to create the engagement needs to be sent as post data in JSON format. 12955 +))) 12956 +(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12957 +((( 12958 +(% class="western" %) 12959 +PUT 12960 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12961 +((( 12962 +(% class="western" %) 12963 +/(% style="color: rgb(33,33,33);" %)engagements(%%)/<engagement id> 12964 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12965 +((( 12966 +(% class="western" %) 12967 +Update engagement by engagement id. The engagement id string 12968 + 12969 +(% class="western" %) 12970 +Parameters required to update the engagement needs to be sent as post data in JSON format. 12971 +))) 12972 +|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12973 +((( 12974 +(% class="western" %) 12975 +POST 12976 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12977 +((( 12978 +(% class="western" %) 12979 +(% style="color: rgb(33,33,33);" %)/engagements/addUser 12980 +)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 12981 +((( 12982 +(% class="western" %) 12983 +Add user to engagement 12984 + 12985 +(% class="western" %) 12986 +Parameters required to add user to the engagement needs to be sent as post data in JSON format. 12987 +))) 12988 + 11882 11882 \\ 11883 11883 12991 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 12992 +== (% class="sc-fzoaKM imuBmi" style="color: rgb(0,127,49);" %)GET (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %)All Engagements(%%) == 12993 + 12994 +---- 12995 + 12996 +---- 12997 + 12998 +{{panel bgColor="#D3D3D3" width="100%"}} 12999 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements 13000 +{{/panel}} 13001 + 13002 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 13003 + 13004 +---- 13005 + 13006 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 13007 + 13008 +==== Example ==== 13009 + 13010 +---- 13011 + 13012 +(% style="color: rgb(107,107,107);" %)Request 13013 + 13014 +{{code language="php" theme="RDark" title="Get All Engagement Request"}} 13015 +<?php 13016 + 13017 +$curl = curl_init(); 13018 + 13019 +curl_setopt_array($curl, array( 13020 + CURLOPT_URL => 'https://api.onecount.net/v2/engagements', 13021 + CURLOPT_RETURNTRANSFER => true, 13022 + CURLOPT_ENCODING => '', 13023 + CURLOPT_MAXREDIRS => 10, 13024 + CURLOPT_TIMEOUT => 0, 13025 + CURLOPT_FOLLOWLOCATION => true, 13026 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 13027 + CURLOPT_CUSTOMREQUEST => 'GET', 13028 + CURLOPT_HTTPHEADER => array( 13029 + 'Appkey: {{ONECOUNT API KEY}}' 13030 + ), 13031 +)); 13032 + 13033 +$response = curl_exec($curl); 13034 + 13035 +curl_close($curl); 13036 +echo $response; 13037 + 13038 + 13039 +{{/code}} 13040 + 11884 11884 \\ 11885 11885 13043 +(% style="color: rgb(107,107,107);" %)Response 200 OK 13044 + 13045 +{{code language="yml" theme="RDark" title="Get all engagements Response" collapse="true"}} 13046 + { 13047 + "result": { 13048 + "success": "1", 13049 + "error": { 13050 + "code": "", 13051 + "message": "" 13052 + } 13053 + }, 13054 + "Engagements": [ 13055 + { 13056 + "Id": "048d38e9-d6c3-432e-9671-3f31809d48b3", 13057 + "Name": "Test Engagement 1", 13058 + "Engagement Fields": [ 13059 + { 13060 + "Name": "id", 13061 + "Type": "text" 13062 + }, 13063 + { 13064 + "Name": "activity_time", 13065 + "Type": "text" 13066 + }, 13067 + { 13068 + "Name": "Name", 13069 + "Type": "text" 13070 + }, 13071 + { 13072 + "Name": "Test Field", 13073 + "Type": "select", 13074 + "Values": [ 13075 + { 13076 + "text": "Test 1", 13077 + "value": "Test1" 13078 + } 13079 + ] 13080 + } 13081 + ] 13082 + } 13083 + ] 13084 +} 13085 +{{/code}} 13086 + 11886 11886 \\ 11887 11887 13089 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 13090 +== (% class="sc-fzoaKM imuBmi" style="color: rgb(0,127,49);" %)GET (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %)Specific Engagement(%%) == 13091 + 13092 +---- 13093 + 13094 +---- 13095 + 13096 +{{panel bgColor="#D3D3D3" width="100%"}} 13097 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements/~{~{Engagement ID}} 13098 +{{/panel}} 13099 + 13100 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 13101 + 13102 +---- 13103 + 13104 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 13105 + 13106 +==== Example ==== 13107 + 13108 +---- 13109 + 13110 +(% style="color: rgb(107,107,107);" %)Request 13111 + 13112 +{{code language="php" theme="RDark" title="Get Specific Engagement Request"}} 13113 +<?php 13114 + 13115 +$curl = curl_init(); 13116 + 13117 +curl_setopt_array($curl, array( 13118 + CURLOPT_URL => 'https://api.onecount.net/v2/engagements/{{Engagement ID}}', 13119 + CURLOPT_RETURNTRANSFER => true, 13120 + CURLOPT_ENCODING => '', 13121 + CURLOPT_MAXREDIRS => 10, 13122 + CURLOPT_TIMEOUT => 0, 13123 + CURLOPT_FOLLOWLOCATION => true, 13124 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 13125 + CURLOPT_CUSTOMREQUEST => 'GET', 13126 + CURLOPT_HTTPHEADER => array( 13127 + 'Appkey: {{ONECOUNT API KEY}}' 13128 + ), 13129 +)); 13130 + 13131 +$response = curl_exec($curl); 13132 + 13133 +curl_close($curl); 13134 +echo $response; 13135 + 13136 + 13137 +{{/code}} 13138 + 11888 11888 \\ 11889 11889 13141 +(% style="color: rgb(107,107,107);" %)Response 200 OK 13142 + 13143 +{{code language="yml" theme="RDark" title="Get specific engagement Response" collapse="true"}} 13144 + { 13145 + "result": { 13146 + "success": "1", 13147 + "error": { 13148 + "code": "", 13149 + "message": "" 13150 + } 13151 + }, 13152 + "Engagements": [ 13153 + { 13154 + "Id": "048d38e9-d6c3-432e-9671-3f31809d48b3", 13155 + "Name": "Test Engagement 1", 13156 + "Engagement Fields": [ 13157 + { 13158 + "Name": "id", 13159 + "Type": "text" 13160 + }, 13161 + { 13162 + "Name": "activity_time", 13163 + "Type": "text" 13164 + }, 13165 + { 13166 + "Name": "Name", 13167 + "Type": "text" 13168 + }, 13169 + { 13170 + "Name": "Test Field", 13171 + "Type": "select", 13172 + "Values": [ 13173 + { 13174 + "text": "Test 1", 13175 + "value": "Test1" 13176 + } 13177 + ] 13178 + } 13179 + ] 13180 + } 13181 + ] 13182 +} 13183 +{{/code}} 13184 + 11890 11890 \\ 11891 11891 13187 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 13188 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Create Engagement(%%) == 13189 + 13190 +---- 13191 + 13192 +{{panel bgColor="#D3D3D3" width="100%"}} 13193 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements 13194 +{{/panel}} 13195 + 13196 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 13197 + 13198 +---- 13199 + 13200 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 13201 + 13202 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 13203 + 13204 +---- 13205 + 13206 +{{code language="yml" theme="RDark" title="Body"}} 13207 +{"Name":"Engagement Name", "Description":"Engagement Description", "Metrics":[ 13208 + {"Name":[{"webinar ID 1":"Webinar 1"},{"webinar ID 3":"Webinar 3"},{"webinar ID 3":"Webinar 3"}],"Type": "select"}, 13209 + {"Attendance Status":[{"attended":"Attended"},{"not_attended":"Not Attended"}],"Type": "select"}, 13210 + {"Price":[],"Type": "numeric"}, 13211 + {"Transaction Date":[],"Type": "date"} 13212 +]} 13213 +{{/code}} 13214 + 13215 +==== Example ==== 13216 + 13217 +---- 13218 + 13219 +(% style="color: rgb(107,107,107);" %)Request 13220 + 13221 +{{code language="php" theme="RDark" title="Create Engagement Request"}} 13222 +<?php 13223 + 13224 +$curl = curl_init(); 13225 + 13226 +curl_setopt_array($curl, array( 13227 + CURLOPT_URL => 'https://api.onecount.net/v2/engagements', 13228 + CURLOPT_RETURNTRANSFER => true, 13229 + CURLOPT_ENCODING => '', 13230 + CURLOPT_MAXREDIRS => 10, 13231 + CURLOPT_TIMEOUT => 0, 13232 + CURLOPT_FOLLOWLOCATION => true, 13233 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 13234 + CURLOPT_CUSTOMREQUEST => 'POST', 13235 + CURLOPT_POSTFIELDS =>'{"Name":"Test engagement 2", "Description":"Test engagement 2", "Metrics":[ 13236 + {"Name":[{"text":"Webinar 1","value":"Webinar_1"},{"text":"Webinar 2","value":"Webinar_2"}],"Type": "select"}, 13237 + {"Attendance Status":[{"text":"Attended","value":"attended"},{"text":"Not Attended","value":"not_attended"}],"Type": "select"}, 13238 + {"Price":[],"Type": "numeric"}, 13239 + {"Transaction Date":[],"Type": "text"} 13240 +]}', 13241 + CURLOPT_HTTPHEADER => array( 13242 + 'Appkey: {{ONECOUNT API KEY}}', 13243 + 'Content-Type: application/json' 13244 + ), 13245 +)); 13246 + 13247 +$response = curl_exec($curl); 13248 + 13249 +curl_close($curl); 13250 +echo $response; 13251 + 13252 + 13253 +{{/code}} 13254 + 11892 11892 \\ 11893 11893 13257 +(% style="color: rgb(107,107,107);" %)Response 200 OK 13258 + 13259 +{{code language="yml" theme="RDark" title="Create Engagement Response" collapse="true"}} 13260 + { 13261 + "result": { 13262 + "success": "1", 13263 + "error": { 13264 + "code": "", 13265 + "message": "" 13266 + } 13267 + }, 13268 + "Engagements": [ 13269 + { 13270 + "Id": "71c1115f-e5bb-470a-bedf-6940f5ac8565", 13271 + "Name": "Test engagement 2", 13272 + "Metrics": [ 13273 + { 13274 + "Name": "Name", 13275 + "Type": "select", 13276 + "Values": [ 13277 + { 13278 + "text": "Webinar 1", 13279 + "value": "Webinar_1" 13280 + }, 13281 + { 13282 + "text": "Webinar 2", 13283 + "value": "Webinar_2" 13284 + } 13285 + ] 13286 + }, 13287 + { 13288 + "Name": "Attendance Status", 13289 + "Type": "select", 13290 + "Values": [ 13291 + { 13292 + "text": "Attended", 13293 + "value": "attended" 13294 + }, 13295 + { 13296 + "text": "Not Attended", 13297 + "value": "not_attended" 13298 + } 13299 + ] 13300 + }, 13301 + { 13302 + "Name": "Price", 13303 + "Type": "numeric" 13304 + }, 13305 + { 13306 + "Name": "Transaction Date", 13307 + "Type": "text" 13308 + }, 13309 + { 13310 + "Name": "id", 13311 + "Type": "text" 13312 + }, 13313 + { 13314 + "Name": "activity_time", 13315 + "Type": "text" 13316 + } 13317 + ] 13318 + } 13319 + ] 13320 +} 13321 +{{/code}} 13322 + 11894 11894 \\ 11895 11895 13325 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 13326 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(0, 83, 184)" %)PUT (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %)Update Engagement(%%) == 13327 + 13328 +---- 13329 + 13330 +{{panel bgColor="#D3D3D3" width="100%"}} 13331 + (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements/~{~{Engagement Id}} 13332 +{{/panel}} 13333 + 13334 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 13335 + 13336 +---- 13337 + 13338 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 13339 + 13340 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 13341 + 13342 +---- 13343 + 13344 +{{code language="yml" theme="RDark" title="Body"}} 13345 +{"Name":"Test engagement 3", "Metrics":[ 13346 + {"Attendance Status":[{"text":"Attended","value":"attended"},{"text":"Not Attended","value":"not_attended"}],"Type": "select"}, 13347 + {"Price":[],"Type": "text"} 13348 + ]} 13349 +{{/code}} 13350 + 13351 +==== Example ==== 13352 + 13353 +---- 13354 + 13355 +(% style="color: rgb(107,107,107);" %)Request 13356 + 13357 +{{code language="php" theme="RDark" title="Update Engagement Request"}} 13358 + <?php 13359 + 13360 +$curl = curl_init(); 13361 + 13362 +curl_setopt_array($curl, array( 13363 + CURLOPT_URL => 'https://api.onecount.net/v2/engagements/{{Engagement Id}}', 13364 + CURLOPT_RETURNTRANSFER => true, 13365 + CURLOPT_ENCODING => '', 13366 + CURLOPT_MAXREDIRS => 10, 13367 + CURLOPT_TIMEOUT => 0, 13368 + CURLOPT_FOLLOWLOCATION => true, 13369 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 13370 + CURLOPT_CUSTOMREQUEST => 'PUT', 13371 + CURLOPT_POSTFIELDS =>'{"Name":"Test engagement 3", "Metrics":[ 13372 + {"Attendance Status":[{"text":"Attended","value":"attended"},{"text":"Not Attended","value":"not_attended"}],"Type": "select"}, 13373 + {"Price":[],"Type": "text"} 13374 + ]}', 13375 + CURLOPT_HTTPHEADER => array( 13376 + 'Appkey: {{ONECOUNT API KEY}}', 13377 + 'Content-Type: application/json' 13378 + ), 13379 +)); 13380 + 13381 +$response = curl_exec($curl); 13382 + 13383 +curl_close($curl); 13384 +echo $response; 13385 + 13386 +{{/code}} 13387 + 11896 11896 \\ 11897 11897 13390 +(% style="color: rgb(107,107,107);" %)Response 200 OK 13391 + 13392 +{{code language="yml" theme="RDark" title="Update Engagement Response" collapse="true"}} 13393 +{ 13394 + "result": { 13395 + "success": "1", 13396 + "error": { 13397 + "code": "", 13398 + "message": "" 13399 + } 13400 + }, 13401 + "Engagements": [ 13402 + { 13403 + "Id": "e0e816ec-77ba-4db1-bfc0-22d340337357", 13404 + "Name": "Test engagement 3", 13405 + "Metrics": [ 13406 + { 13407 + "Name": "Attendance Status", 13408 + "Type": "select", 13409 + "Values": [ 13410 + { 13411 + "text": "Attended", 13412 + "value": "attended" 13413 + }, 13414 + { 13415 + "text": "Not Attended", 13416 + "value": "not_attended" 13417 + } 13418 + ] 13419 + }, 13420 + { 13421 + "Name": "Price", 13422 + "Type": "text" 13423 + }, 13424 + { 13425 + "Name": "Name", 13426 + "Type": "select", 13427 + "Values": [ 13428 + { 13429 + "text": "Webinar 1", 13430 + "value": "Webinar_1" 13431 + }, 13432 + { 13433 + "text": "Webinar 2", 13434 + "value": "Webinar_2" 13435 + } 13436 + ] 13437 + }, 13438 + { 13439 + "Name": "Transaction Date", 13440 + "Type": "text" 13441 + }, 13442 + { 13443 + "Name": "id", 13444 + "Type": "text" 13445 + }, 13446 + { 13447 + "Name": "activity_time", 13448 + "Type": "text" 13449 + } 13450 + ] 13451 + } 13452 + ] 13453 +} 13454 +{{/code}} 13455 + 11898 11898 \\ 11899 11899 13458 +(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 13459 +== (% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33, 33, 33); color: rgb(173, 122, 3)" %)POST(% class="sc-fzomuh jbmEtY documentation-core-item-request-name" style="color: rgb(33,33,33);" %) Add User to Engagement(%%) == 13460 + 13461 +---- 13462 + 13463 +{{panel bgColor="#D3D3D3" width="100%"}} 13464 +(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements/addUser 13465 +{{/panel}} 13466 + 13467 +=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 13468 + 13469 +---- 13470 + 13471 +(% class="Text__TextContainer-sc-1kqigik-0 iauueY sc-fznXWL cEvDCP item-key" style="color: rgb(33,33,33);" %)Appkey (% class="Text__TextContainer-sc-1kqigik-0 iYynAw" style="color: rgb(33,33,33);" %)~{~{ONECOUNT API KEY}} 13472 + 13473 +=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 13474 + 13475 +---- 13476 + 13477 +{{code language="yml" theme="RDark" title="Body"}} 13478 +{"engagement id":"e0e816ec-77ba-4db1-bfc0-22d340337357","show id":"Webinar_1","ocid":"1845775", "date":"2023-12-31 14:12:38", "data":{"price":"10","attendance_status":"not_attended"},"segment":{}} 13479 +{{/code}} 13480 + 13481 +==== Example ==== 13482 + 13483 +---- 13484 + 13485 +(% style="color: rgb(107,107,107);" %)Request 13486 + 13487 +{{code language="php" theme="RDark" title="Add User to Engagement Request"}} 13488 + <?php 13489 + 13490 +$curl = curl_init(); 13491 + 13492 +curl_setopt_array($curl, array( 13493 + CURLOPT_URL => 'https://api.onecount.net/v2/engagements/addUser', 13494 + CURLOPT_RETURNTRANSFER => true, 13495 + CURLOPT_ENCODING => '', 13496 + CURLOPT_MAXREDIRS => 10, 13497 + CURLOPT_TIMEOUT => 0, 13498 + CURLOPT_FOLLOWLOCATION => true, 13499 + CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 13500 + CURLOPT_CUSTOMREQUEST => 'POST', 13501 + CURLOPT_POSTFIELDS =>'{"engagement id":"e0e816ec-77ba-4db1-bfc0-22d340337357","show id":"Webinar_1","ocid":"1845775", "date":"2023-12-31 14:12:38", "data":{"price":"10","attendance_status":"not_attended"},"segment":{}}', 13502 + CURLOPT_HTTPHEADER => array( 13503 + 'Appkey: {{ONECOUNT API KEY}}' 13504 + ), 13505 +)); 13506 + 13507 +$response = curl_exec($curl); 13508 + 13509 +curl_close($curl); 13510 +echo $response; 13511 +{{/code}} 13512 + 11900 11900 \\ 11901 11901 13515 +(% style="color: rgb(107,107,107);" %)Response 200 OK 13516 + 13517 +{{code language="yml" theme="RDark" title="Add Users to Engagement Response" collapse="true"}} 13518 + { 13519 + "result": { 13520 + "success": "1", 13521 + "error": { 13522 + "code": "", 13523 + "message": "" 13524 + } 13525 + }, 13526 + "Users": { 13527 + "ocid": 1845775, 13528 + "uuid": { 13529 + "type": { 13530 + "name": "uuid" 13531 + }, 13532 + "uuid": "a1425a04-4c0c-4790-bcd6-425bc7729fd7", 13533 + "version": 4 13534 + }, 13535 + "blacklisted": null, 13536 + "demo": { 13537 + "1": "rayaan@one-count.com", 13538 + "2": "user_1701788987", 13539 + "3": "5994471abb01112afcc18159f6cc74b4f511b99806da59b3caf5a9c173cacfc5" 13540 + }, 13541 + "email": "rayaan@one-count.com", 13542 + "espid": null, 13543 + "known": { 13544 + "type": { 13545 + "name": "smallint" 13546 + }, 13547 + "value": "1" 13548 + }, 13549 + "ocid_hash": "57b81cf5536171c84e6e8a0b762251ee7819737b2e95f1390fed97acc11a277b", 13550 + "partners_hash": null, 13551 + "password": "5994471abb01112afcc18159f6cc74b4f511b99806da59b3caf5a9c173cacfc5", 13552 + "payment_cc_exp": null, 13553 + "payment_vendor_token": null, 13554 + "products": { 13555 + "599": "447" 13556 + }, 13557 + "remarks": null, 13558 + "resources": null, 13559 + "smartlink_hash": null, 13560 + "subscription_active_resource_info": null, 13561 + "subscription_active_term_info": { 13562 + "447": "{\"renewed\":1,\"expiration_month\":202512,\"product_status\":\"2\",\"expiration_date\":20251211}" 13563 + }, 13564 + "subscription_log": { 13565 + "type": { 13566 + "valueType": { 13567 + "name": "varchar" 13568 + } 13569 + }, 13570 + "values": [ 13571 + "{\"batch_id\":\"1234\",\"__cuuid\":\"49\",\"subscription_time\":\"2023-12-11 09:09:01\",\"product_status\":\"2\",\"promo_code\":\"\",\"type\":\"term\",\"expiration_date\":20251211,\"subscription_date\":20231211,\"ocid\":1845775,\"product_uid\":\"599\",\"timestamp\":1702303741,\"amount\":0,\"quantity\":1,\"import_id\":\"83\",\"ip\":\"10.10.20.7\",\"form_id\":\"8f93834c-adce-4dc7-acd0-f3a1e0f7c63f\",\"previous_expiration_date\":20231211,\"term_uid\":\"447\",\"renewed\":1,\"request_date\":20231211,\"payment_transaction_id\":\"0\",\"subscription_type\":\"n\",\"payment_processor\":\"\",\"remarks\":\"USER SUBSCRIBED\",\"user_uid\":\"a1425a04-4c0c-4790-bcd6-425bc7729fd7\"}", 13572 + "{\"batch_id\":\"1234\",\"__cuuid\":\"49\",\"subscription_time\":\"2023-12-11 09:20:49\",\"product_status\":\"2\",\"promo_code\":\"\",\"type\":\"term\",\"expiration_date\":20251211,\"subscription_date\":20231211,\"ocid\":1845775,\"product_uid\":\"599\",\"timestamp\":1702304449,\"amount\":0,\"quantity\":1,\"import_id\":\"83\",\"ip\":\"10.10.20.7\",\"form_id\":\"8f93834c-adce-4dc7-acd0-f3a1e0f7c63f\",\"previous_expiration_date\":20231211,\"term_uid\":\"447\",\"renewed\":1,\"request_date\":20231211,\"payment_transaction_id\":\"0\",\"subscription_type\":\"n\",\"payment_processor\":\"\",\"remarks\":\"USER SUBSCRIBED\",\"user_uid\":\"a1425a04-4c0c-4790-bcd6-425bc7729fd7\"}", 13573 + "{\"batch_id\":\"1234\",\"__cuuid\":\"49\",\"subscription_time\":\"2023-12-11 09:34:26\",\"product_status\":\"2\",\"promo_code\":\"\",\"type\":\"term\",\"expiration_date\":20251211,\"subscription_date\":20231211,\"ocid\":1845775,\"product_uid\":\"599\",\"timestamp\":1702305266,\"amount\":0,\"quantity\":1,\"import_id\":\"83\",\"ip\":\"10.10.20.7\",\"form_id\":\"8f93834c-adce-4dc7-acd0-f3a1e0f7c63f\",\"previous_expiration_date\":20231211,\"term_uid\":\"447\",\"renewed\":1,\"request_date\":20231211,\"payment_transaction_id\":\"0\",\"subscription_type\":\"n\",\"payment_processor\":\"\",\"remarks\":\"USER SUBSCRIBED\",\"user_uid\":\"a1425a04-4c0c-4790-bcd6-425bc7729fd7\"}" 13574 + ] 13575 + }, 13576 + "subscription_log_by_resource": null, 13577 + "subscription_source_code": [ 13578 + "83" 13579 + ], 13580 + "targets": null, 13581 + "timestamp": { 13582 + "type": { 13583 + "name": "bigint" 13584 + }, 13585 + "value": "1701788987" 13586 + }, 13587 + "unconfirmed": null, 13588 + "update_time": null, 13589 + "username": "user_1701788987", 13590 + "vendor_blacklisted": null, 13591 + "vendor_esp": null, 13592 + "vendor_unconfirmed": null 13593 + } 13594 +} 13595 +{{/code}} 13596 + 11902 11902 \\ 11903 11903 11904 11904 (% class="western" %) 11905 -**COMPONENT: Leads 11906 -** 13600 +=== **COMPONENT: Leads 13601 +** === 11907 11907 11908 11908 (% class="western" %) 11909 11909 Stats resource can be used to submit any type of stat collected on the third party systems. Each type of stat will be represented by a sub-resource. So, for telemarketing it could be **/stats/telemarketing** endpoint, for videos it can be **/stats/videos**, for webinar it could be **/stats/webinars** etc. Right now we only have telemarketing sub-resource. ... ... @@ -12088,14 +12088,6 @@ 12088 12088 12089 12089 \\ 12090 12090 12091 -\\ 12092 - 12093 -\\ 12094 - 12095 -\\ 12096 - 12097 -\\ 12098 - 12099 12099 (% class="western" %) 12100 12100 **API REFERENCE** 12101 12101
- Confluence.Code.ConfluencePageClass[0]
-
- id
-
... ... @@ -1,1 +1,1 @@ 1 -10 82654811 +110231562 - url
-
... ... @@ -1,1 +1,1 @@ 1 -https://info.onecount.net//wiki/spaces/OD/pages/10 8265481/ONEcount API Documentation1 +https://info.onecount.net//wiki/spaces/OD/pages/110231562/ONEcount API Documentation