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
-
... ... @@ -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.230 +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 ((( ... ... @@ -341,7 +341,7 @@ 341 341 $curl = curl_init(); 342 342 343 343 curl_setopt_array($curl, array( 344 - CURLOPT_URL => ' https://api.onecount.net/v2/users',344 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/users', 345 345 CURLOPT_RETURNTRANSFER => true, 346 346 CURLOPT_ENCODING => '', 347 347 CURLOPT_MAXREDIRS => 10, ... ... @@ -881,7 +881,7 @@ 881 881 $curl = curl_init(); 882 882 883 883 curl_setopt_array($curl, array( 884 - CURLOPT_URL => ' https://api.onecount.net/v2/users/{{OCID}}',884 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/users/8418', 885 885 CURLOPT_RETURNTRANSFER => true, 886 886 CURLOPT_ENCODING => '', 887 887 CURLOPT_MAXREDIRS => 10, ... ... @@ -989,7 +989,7 @@ 989 989 $curl = curl_init(); 990 990 991 991 curl_setopt_array($curl, array( 992 - CURLOPT_URL => ' https://api.onecount.net/v2/users/login',992 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/users/login', 993 993 CURLOPT_RETURNTRANSFER => true, 994 994 CURLOPT_ENCODING => '', 995 995 CURLOPT_MAXREDIRS => 10, ... ... @@ -1064,7 +1064,7 @@ 1064 1064 $curl = curl_init(); 1065 1065 1066 1066 curl_setopt_array($curl, array( 1067 - CURLOPT_URL => ' https://api.onecount.net/v2/users/lookup?2=user_242_6298&return=1,2,3,4',1067 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/users/lookup?2=user_242_6298&return=1%2C2%2C3%2C4', 1068 1068 CURLOPT_RETURNTRANSFER => true, 1069 1069 CURLOPT_ENCODING => '', 1070 1070 CURLOPT_MAXREDIRS => 10, ... ... @@ -1141,7 +1141,6 @@ 1141 1141 (% class="western" %) 1142 1142 **POST method should be used to create users.** 1143 1143 1144 -(% class="wrapped" %) 1145 1145 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1146 1146 ((( 1147 1147 (% class="western" %) ... ... @@ -1208,7 +1208,6 @@ 1208 1208 CSV of ONEcount QuestionId's requested back in Users object in response. 1209 1209 ))) 1210 1210 1211 -(% class="wrapped" %) 1212 1212 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1213 1213 ((( 1214 1214 (% class="western" %) ... ... @@ -1262,7 +1262,7 @@ 1262 1262 $curl = curl_init(); 1263 1263 1264 1264 curl_setopt_array($curl, array( 1265 - CURLOPT_URL => ' https://api.onecount.net/v2/users',1263 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/users', 1266 1266 CURLOPT_RETURNTRANSFER => true, 1267 1267 CURLOPT_ENCODING => '', 1268 1268 CURLOPT_MAXREDIRS => 10, ... ... @@ -1318,7 +1318,6 @@ 1318 1318 (% class="western" %) 1319 1319 **PUT method should be used to update users.** 1320 1320 1321 -(% class="wrapped" %) 1322 1322 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1323 1323 ((( 1324 1324 (% class="western" %) ... ... @@ -1372,7 +1372,6 @@ 1372 1372 RequestDate to use for the demo update. If not provided current date will be used. 1373 1373 ))) 1374 1374 1375 -(% class="wrapped" %) 1376 1376 (% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %) 1377 1377 ((( 1378 1378 (% class="western" %) ... ... @@ -1426,7 +1426,7 @@ 1426 1426 $curl = curl_init(); 1427 1427 1428 1428 curl_setopt_array($curl, array( 1429 - CURLOPT_URL => ' https://api.onecount.net/v2/users/{{OCID}}',1425 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/users/{{OCID}}', 1430 1430 CURLOPT_RETURNTRANSFER => true, 1431 1431 CURLOPT_ENCODING => '', 1432 1432 CURLOPT_MAXREDIRS => 10, ... ... @@ -1670,7 +1670,7 @@ 1670 1670 $curl = curl_init(); 1671 1671 1672 1672 curl_setopt_array($curl, array( 1673 - CURLOPT_URL => ' https://api.onecount.net/v2/questions',1669 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/questions', 1674 1674 CURLOPT_RETURNTRANSFER => true, 1675 1675 CURLOPT_ENCODING => '', 1676 1676 CURLOPT_MAXREDIRS => 10, ... ... @@ -3811,7 +3811,7 @@ 3811 3811 $curl = curl_init(); 3812 3812 3813 3813 curl_setopt_array($curl, array( 3814 - CURLOPT_URL => ' https://api.onecount.net/v2/questions/{{QUESTION ID}}',3810 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/questions/{{QUESTION ID}}', 3815 3815 CURLOPT_RETURNTRANSFER => true, 3816 3816 CURLOPT_ENCODING => '', 3817 3817 CURLOPT_MAXREDIRS => 10, ... ... @@ -3890,7 +3890,7 @@ 3890 3890 $curl = curl_init(); 3891 3891 3892 3892 curl_setopt_array($curl, array( 3893 - CURLOPT_URL => ' https://api.onecount.net/v2/questions/lookup?Text=COUNTRY',3889 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/questions/lookup?Text=COUNTRY', 3894 3894 CURLOPT_RETURNTRANSFER => true, 3895 3895 CURLOPT_ENCODING => '', 3896 3896 CURLOPT_MAXREDIRS => 10, ... ... @@ -5336,7 +5336,7 @@ 5336 5336 $curl = curl_init(); 5337 5337 5338 5338 curl_setopt_array($curl, array( 5339 - CURLOPT_URL => ' https://api.onecount.net/v2/questions/lookup?Type=4',5335 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/questions/lookup?Type=4', 5340 5340 CURLOPT_RETURNTRANSFER => true, 5341 5341 CURLOPT_ENCODING => '', 5342 5342 CURLOPT_MAXREDIRS => 10, ... ... @@ -8043,7 +8043,7 @@ 8043 8043 $curl = curl_init(); 8044 8044 8045 8045 curl_setopt_array($curl, array( 8046 - CURLOPT_URL => ' https://api.onecount.net/v2/questions',8042 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/questions', 8047 8047 CURLOPT_RETURNTRANSFER => true, 8048 8048 CURLOPT_ENCODING => '', 8049 8049 CURLOPT_MAXREDIRS => 10, ... ... @@ -8121,7 +8121,7 @@ 8121 8121 $curl = curl_init(); 8122 8122 8123 8123 curl_setopt_array($curl, array( 8124 - CURLOPT_URL => ' https://api.onecount.net/v2/questions',8120 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/questions', 8125 8125 CURLOPT_RETURNTRANSFER => true, 8126 8126 CURLOPT_ENCODING => '', 8127 8127 CURLOPT_MAXREDIRS => 10, ... ... @@ -8199,7 +8199,7 @@ 8199 8199 $curl = curl_init(); 8200 8200 8201 8201 curl_setopt_array($curl, array( 8202 - CURLOPT_URL => ' https://api.onecount.net/v2/questions/{{QUESTION ID}}',8198 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/questions/503', 8203 8203 CURLOPT_RETURNTRANSFER => true, 8204 8204 CURLOPT_ENCODING => '', 8205 8205 CURLOPT_MAXREDIRS => 10, ... ... @@ -8384,7 +8384,7 @@ 8384 8384 $curl = curl_init(); 8385 8385 8386 8386 curl_setopt_array($curl, array( 8387 - CURLOPT_URL => ' https://api.onecount.net/v2/products',8383 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/products', 8388 8388 CURLOPT_RETURNTRANSFER => true, 8389 8389 CURLOPT_ENCODING => '', 8390 8390 CURLOPT_MAXREDIRS => 10, ... ... @@ -8672,7 +8672,7 @@ 8672 8672 $curl = curl_init(); 8673 8673 8674 8674 curl_setopt_array($curl, array( 8675 - CURLOPT_URL => ' https://api.onecount.net/v2/users/products/{{product id}}',8671 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/products/{{Product id}}', 8676 8676 CURLOPT_RETURNTRANSFER => true, 8677 8677 CURLOPT_ENCODING => '', 8678 8678 CURLOPT_MAXREDIRS => 10, ... ... @@ -8762,7 +8762,7 @@ 8762 8762 $curl = curl_init(); 8763 8763 8764 8764 curl_setopt_array($curl, array( 8765 - CURLOPT_URL => ' https://api.onecount.net/v2/products/lookup?Title={{ProductName}}',8761 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/products/lookup?Title={{Package Name}}', 8766 8766 CURLOPT_RETURNTRANSFER => true, 8767 8767 CURLOPT_ENCODING => '', 8768 8768 CURLOPT_MAXREDIRS => 10, ... ... @@ -8815,165 +8815,104 @@ 8815 8815 8816 8816 \\ 8817 8817 8818 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 8819 -== (% 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(%%) == 8814 +\\ 8820 8820 8821 - ----8816 +\\ 8822 8822 8823 -{{panel bgColor="#D3D3D3" width="100%"}} 8824 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/products 8825 -{{/panel}} 8818 +\\ 8826 8826 8827 - === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===8820 +\\ 8828 8828 8829 - ----8822 +\\ 8830 8830 8831 - (% 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}}8824 +\\ 8832 8832 8833 - === (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===8826 +\\ 8834 8834 8835 - ----8828 +\\ 8836 8836 8837 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 8838 -{"Title":"Test API package creation 2","Description": "Test API package creation 2","Terms":{"Name":"Test term for API 2"},"PrimaryFormId":0} 8839 -{{/code}} 8830 +\\ 8840 8840 8841 - ==== Example ====8832 +\\ 8842 8842 8843 - ----8834 +\\ 8844 8844 8845 - (% style="color: rgb(107,107,107);" %)Request8836 +\\ 8846 8846 8847 -{{code language="php" theme="RDark" title="Create Product Request" collapse="true"}} 8848 - <?php 8838 +\\ 8849 8849 8850 - $curl = curl_init();8840 +\\ 8851 8851 8852 -curl_setopt_array($curl, array( 8853 - CURLOPT_URL => 'https://api.onecount.net/v2/products', 8854 - CURLOPT_RETURNTRANSFER => true, 8855 - CURLOPT_ENCODING => '', 8856 - CURLOPT_MAXREDIRS => 10, 8857 - CURLOPT_TIMEOUT => 0, 8858 - CURLOPT_FOLLOWLOCATION => true, 8859 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 8860 - CURLOPT_CUSTOMREQUEST => 'POST', 8861 - CURLOPT_POSTFIELDS =>'{"Title":"Test API package creation 1","Description": "Test API package creation 1","Terms":{"Name":"Test term for API 1"},"PrimaryFormId":0}', 8862 - CURLOPT_HTTPHEADER => array( 8863 - 'Appkey: {{ONECOUNT API KEY}}' 8864 - ), 8865 -)); 8842 +\\ 8866 8866 8867 - $response = curl_exec($curl);8844 +\\ 8868 8868 8869 -curl_close($curl); 8870 -echo $response; 8871 -{{/code}} 8846 +\\ 8872 8872 8873 8873 \\ 8874 8874 8875 - (% style="color: rgb(107,107,107);" %)Response 200 OK8850 +\\ 8876 8876 8877 -{{code language="yml" theme="RDark" title="Create Product Response" collapse="true"}} 8878 - { 8879 - "result": { 8880 - "success": "1", 8881 - "error": { 8882 - "code": "", 8883 - "message": "" 8884 - } 8885 - }, 8886 - "Products": [ 8887 - { 8888 - "ProductId": 599 8889 - } 8890 - ] 8891 -} 8892 -{{/code}} 8852 +\\ 8893 8893 8894 8894 \\ 8895 8895 8896 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 8897 -== (% 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(%%) == 8856 +\\ 8898 8898 8899 - ----8858 +\\ 8900 8900 8901 -{{panel bgColor="#D3D3D3" width="100%"}} 8902 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/products/~{~{Product id}} 8903 -{{/panel}} 8860 +\\ 8904 8904 8905 - === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===8862 +\\ 8906 8906 8907 - ----8864 +\\ 8908 8908 8909 - (% 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}}8866 +\\ 8910 8910 8911 - === (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===8868 +\\ 8912 8912 8913 - ----8870 +\\ 8914 8914 8915 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 8916 -{"Title":"Test API package 23","Description": "Test API package 23","PrimaryFormId":0} 8917 -{{/code}} 8872 +\\ 8918 8918 8919 - ==== Example ====8874 +\\ 8920 8920 8921 - ----8876 +\\ 8922 8922 8923 - (% style="color: rgb(107,107,107);" %)Request8878 +\\ 8924 8924 8925 -{{code language="php" theme="RDark" title="Update Product Request" collapse="true"}} 8926 -<?php 8880 +\\ 8927 8927 8928 - $curl = curl_init();8882 +\\ 8929 8929 8930 -curl_setopt_array($curl, array( 8931 - CURLOPT_URL => 'https://api.onecount.net/v2/products/{{Product id}}', 8932 - CURLOPT_RETURNTRANSFER => true, 8933 - CURLOPT_ENCODING => '', 8934 - CURLOPT_MAXREDIRS => 10, 8935 - CURLOPT_TIMEOUT => 0, 8936 - CURLOPT_FOLLOWLOCATION => true, 8937 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 8938 - CURLOPT_CUSTOMREQUEST => 'PUT', 8939 - CURLOPT_POSTFIELDS =>'{"Title":"Test API package 1","Description": "Test API package 1","PrimaryFormId":0}', 8940 - CURLOPT_HTTPHEADER => array( 8941 - 'Appkey: {{ONECOUNT API KEY}}' 8942 - ), 8943 -)); 8884 +\\ 8944 8944 8945 - $response = curl_exec($curl);8886 +\\ 8946 8946 8947 -curl_close($curl); 8948 -echo $response; 8949 - 8950 -{{/code}} 8888 +\\ 8951 8951 8952 8952 \\ 8953 8953 8954 - (% style="color: rgb(107,107,107);" %)Response 200 OK8892 +\\ 8955 8955 8956 -{{code language="yml" theme="RDark" title="Update Product Response" collapse="true"}} 8957 - { 8958 - "result": { 8959 - "success": "1", 8960 - "error": { 8961 - "code": "", 8962 - "message": "" 8963 - } 8964 - }, 8965 - "Products": [ 8966 - { 8967 - "ProductId": 599, 8968 - "Title": "Test API package 1", 8969 - "Description": "Test API package 1" 8970 - } 8971 - ] 8972 -} 8973 -{{/code}} 8894 +\\ 8974 8974 8975 8975 \\ 8976 8976 8898 +\\ 8899 + 8900 +\\ 8901 + 8902 +\\ 8903 + 8904 +\\ 8905 + 8906 +\\ 8907 + 8908 +\\ 8909 + 8910 +\\ 8911 + 8977 8977 (% class="western" %) 8978 8978 **COMPONENT: Terms** 8979 8979 ... ... @@ -9078,7 +9078,7 @@ 9078 9078 $curl = curl_init(); 9079 9079 9080 9080 curl_setopt_array($curl, array( 9081 - CURLOPT_URL => ' https://api.onecount.net/v2/terms',9016 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/terms', 9082 9082 CURLOPT_RETURNTRANSFER => true, 9083 9083 CURLOPT_ENCODING => '', 9084 9084 CURLOPT_MAXREDIRS => 10, ... ... @@ -9261,7 +9261,7 @@ 9261 9261 $curl = curl_init(); 9262 9262 9263 9263 curl_setopt_array($curl, array( 9264 - CURLOPT_URL => ' https://api.onecount.net/v2/terms/{{Term Id}}',9199 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/terms/{{Term Id}}', 9265 9265 CURLOPT_RETURNTRANSFER => true, 9266 9266 CURLOPT_ENCODING => '', 9267 9267 CURLOPT_MAXREDIRS => 10, ... ... @@ -9342,7 +9342,7 @@ 9342 9342 $curl = curl_init(); 9343 9343 9344 9344 curl_setopt_array($curl, array( 9345 - CURLOPT_URL => ' https://api.onecount.net/v2/terms/lookup?Name={{Term Name}}',9280 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/terms/lookup?Name={{Term Name}} ', 9346 9346 CURLOPT_RETURNTRANSFER => true, 9347 9347 CURLOPT_ENCODING => '', 9348 9348 CURLOPT_MAXREDIRS => 10, ... ... @@ -9365,195 +9365,16 @@ 9365 9365 9366 9366 (% style="color: rgb(107,107,107);" %)Response 200 OK 9367 9367 9368 -{{code language="yml" theme="RDark" title="Lookup Term Response" collapse="true"}} 9369 -{ 9370 - "result": { 9371 - "success": "1", 9372 - "error": { 9373 - "code": "", 9374 - "message": "" 9375 - } 9376 - }, 9377 - "Terms": [ 9378 - { 9379 - "Id": 431, 9380 - "Name": "Test term for API 1", 9381 - "Description": null, 9382 - "Duration": 0, 9383 - "DurationUnit": "", 9384 - "Price": "0.00", 9385 - "ProductId": 599 9386 - } 9387 - ] 9388 -} 9389 -{{/code}} 9303 +{{code language="yml" theme="RDark" title="Lookup Term Response" collapse="true"/}} 9390 9390 9391 9391 \\ 9392 9392 9393 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 9394 -== (% 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(%%) == 9395 - 9396 ----- 9397 - 9398 -{{panel bgColor="#D3D3D3" width="100%"}} 9399 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/terms 9400 -{{/panel}} 9401 - 9402 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 9403 - 9404 ----- 9405 - 9406 -(% 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}} 9407 - 9408 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 9409 - 9410 ----- 9411 - 9412 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 9413 -{"Name":"Test API term creation","Description":"Test API term creation","Duration":10,"ProductId":599} 9414 -{{/code}} 9415 - 9416 -==== Example ==== 9417 - 9418 ----- 9419 - 9420 -(% style="color: rgb(107,107,107);" %)Request 9421 - 9422 -{{code language="php" theme="RDark" title="Create Term Request" collapse="true"}} 9423 -<?php 9424 - 9425 -$curl = curl_init(); 9426 - 9427 -curl_setopt_array($curl, array( 9428 - CURLOPT_URL => 'https://api.onecount.net/v2/terms', 9429 - CURLOPT_RETURNTRANSFER => true, 9430 - CURLOPT_ENCODING => '', 9431 - CURLOPT_MAXREDIRS => 10, 9432 - CURLOPT_TIMEOUT => 0, 9433 - CURLOPT_FOLLOWLOCATION => true, 9434 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 9435 - CURLOPT_CUSTOMREQUEST => 'POST', 9436 - CURLOPT_POSTFIELDS =>'{"Name":"Test API term creation","Description":"Test API term creation","Duration":10,"ProductId":599} 9437 - 9438 -', 9439 - CURLOPT_HTTPHEADER => array( 9440 - 'Appkey: {{ONECOUNT API KEY}}' 9441 - ), 9442 -)); 9443 - 9444 -$response = curl_exec($curl); 9445 - 9446 -curl_close($curl); 9447 -echo $response; 9448 - 9449 - 9450 -{{/code}} 9451 - 9452 9452 \\ 9453 9453 9454 -(% style="color: rgb(107,107,107);" %)Response 200 OK 9455 - 9456 -{{code language="yml" theme="RDark" title="Create Term Response" collapse="true"}} 9457 -{ 9458 - "result": { 9459 - "success": "1", 9460 - "error": { 9461 - "code": "", 9462 - "message": "" 9463 - } 9464 - }, 9465 - "Terms": [ 9466 - { 9467 - "Id": 447 9468 - } 9469 - ] 9470 -} 9471 -{{/code}} 9472 - 9473 9473 \\ 9474 9474 9475 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 9476 -== (% 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(%%) == 9477 - 9478 ----- 9479 - 9480 -{{panel bgColor="#D3D3D3" width="100%"}} 9481 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/terms/~{~{Term Id}} 9482 -{{/panel}} 9483 - 9484 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 9485 - 9486 ----- 9487 - 9488 -(% 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}} 9489 - 9490 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 9491 - 9492 ----- 9493 - 9494 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 9495 -{"Name":"Test API term creation update","Description":"Test API term creation update","Duration":10,"ProductId":599} 9496 -{{/code}} 9497 - 9498 -==== Example ==== 9499 - 9500 ----- 9501 - 9502 -(% style="color: rgb(107,107,107);" %)Request 9503 - 9504 -{{code language="php" theme="RDark" title="Update Term Request" collapse="true"}} 9505 - <?php 9506 - 9507 -$curl = curl_init(); 9508 - 9509 -curl_setopt_array($curl, array( 9510 - CURLOPT_URL => 'https://api.onecount.net/v2/terms/{{Term Id}}', 9511 - CURLOPT_RETURNTRANSFER => true, 9512 - CURLOPT_ENCODING => '', 9513 - CURLOPT_MAXREDIRS => 10, 9514 - CURLOPT_TIMEOUT => 0, 9515 - CURLOPT_FOLLOWLOCATION => true, 9516 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 9517 - CURLOPT_CUSTOMREQUEST => 'PUT', 9518 - CURLOPT_POSTFIELDS =>'{"Name":"Test API term creation update","Description":"Test API term creation update","Duration":10,"ProductId":599}', 9519 - CURLOPT_HTTPHEADER => array( 9520 - 'Appkey: {{ONECOUNT API KEY}}' 9521 - ), 9522 -)); 9523 - 9524 -$response = curl_exec($curl); 9525 - 9526 -curl_close($curl); 9527 -echo $response; 9528 -{{/code}} 9529 - 9530 9530 \\ 9531 9531 9532 -(% style="color: rgb(107,107,107);" %)Response 200 OK 9533 - 9534 -{{code language="yml" theme="RDark" title="Update Term Response" collapse="true"}} 9535 - { 9536 - "result": { 9537 - "success": "1", 9538 - "error": { 9539 - "code": "", 9540 - "message": "" 9541 - } 9542 - }, 9543 - "Terms": [ 9544 - { 9545 - "Id": 447, 9546 - "Name": "Test API term creation update", 9547 - "Description": "Test API term creation update", 9548 - "Duration": 10, 9549 - "DurationUnit": "", 9550 - "Price": "0.00", 9551 - "ProductId": 599 9552 - } 9553 - ] 9554 -} 9555 -{{/code}} 9556 - 9557 9557 \\ 9558 9558 9559 9559 (% class="western" %) ... ... @@ -9695,7 +9695,7 @@ 9695 9695 $curl = curl_init(); 9696 9696 9697 9697 curl_setopt_array($curl, array( 9698 - CURLOPT_URL => ' https://api.onecount.net/v2/resources',9454 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/resources?limit=10', 9699 9699 CURLOPT_RETURNTRANSFER => true, 9700 9700 CURLOPT_ENCODING => '', 9701 9701 CURLOPT_MAXREDIRS => 10, ... ... @@ -9841,7 +9841,7 @@ 9841 9841 $curl = curl_init(); 9842 9842 9843 9843 curl_setopt_array($curl, array( 9844 - CURLOPT_URL => ' https://api.onecount.net/v2/resources/{{Resource ID}}',9600 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/resources/{{Resource ID}}', 9845 9845 CURLOPT_RETURNTRANSFER => true, 9846 9846 CURLOPT_ENCODING => '', 9847 9847 CURLOPT_MAXREDIRS => 10, ... ... @@ -9894,7 +9894,7 @@ 9894 9894 ---- 9895 9895 9896 9896 {{panel bgColor="#D3D3D3" width="100%"}} 9897 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/ resources/lookup?Name={(%%){ResourceName}}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,4 9898 9898 {{/panel}} 9899 9899 9900 9900 === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === ... ... @@ -9907,7 +9907,8 @@ 9907 9907 9908 9908 ---- 9909 9909 9910 -(% 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}} 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 9911 9911 9912 9912 ==== Example ==== 9913 9913 ... ... @@ -9915,231 +9915,24 @@ 9915 9915 9916 9916 (% style="color: rgb(107,107,107);" %)Request 9917 9917 9918 -{{code language="php" theme="RDark" title="Lookup Resource Request" collapse="true"}} 9919 - <?php 9675 +{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}} 9920 9920 9921 -$curl = curl_init(); 9922 - 9923 -curl_setopt_array($curl, array( 9924 - CURLOPT_URL => 'https://api.onecount.net/v2/resources/lookup?Name={{Resource Name}}', 9925 - CURLOPT_RETURNTRANSFER => true, 9926 - CURLOPT_ENCODING => '', 9927 - CURLOPT_MAXREDIRS => 10, 9928 - CURLOPT_TIMEOUT => 0, 9929 - CURLOPT_FOLLOWLOCATION => true, 9930 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 9931 - CURLOPT_CUSTOMREQUEST => 'GET', 9932 - CURLOPT_HTTPHEADER => array( 9933 - 'Appkey: {{ONECOUNT API KEY}}' 9934 - ), 9935 -)); 9936 - 9937 -$response = curl_exec($curl); 9938 - 9939 -curl_close($curl); 9940 -echo $response; 9941 -{{/code}} 9942 - 9943 9943 \\ 9944 9944 9945 9945 (% style="color: rgb(107,107,107);" %)Response 200 OK 9946 9946 9947 -{{code language="yml" theme="RDark" title="Lookup Resource Response" collapse="true"}} 9948 - { 9949 - "result": { 9950 - "success": "1", 9951 - "error": { 9952 - "code": "", 9953 - "message": "" 9954 - } 9955 - }, 9956 - "Resources": [ 9957 - { 9958 - "Id": 479, 9959 - "Name": "Virtualization Review", 9960 - "Description": "", 9961 - "Type": "0", 9962 - "Value": "", 9963 - "FreePass": 0 9964 - } 9965 - ] 9966 -} 9967 -{{/code}} 9681 +{{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"/}} 9968 9968 9969 9969 \\ 9970 9970 9971 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 9972 -== (% 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(%%) == 9685 +\\ 9973 9973 9974 ----- 9975 - 9976 -{{panel bgColor="#D3D3D3" width="100%"}} 9977 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources 9978 -{{/panel}} 9979 - 9980 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 9981 - 9982 ----- 9983 - 9984 -(% 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}} 9985 - 9986 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 9987 - 9988 ----- 9989 - 9990 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 9991 -{"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} 9992 -{{/code}} 9993 - 9994 -==== Example ==== 9995 - 9996 ----- 9997 - 9998 -(% style="color: rgb(107,107,107);" %)Request 9999 - 10000 -{{code language="php" theme="RDark" title="Create Resource Request" collapse="true"}} 10001 - <?php 10002 - 10003 -$curl = curl_init(); 10004 - 10005 -curl_setopt_array($curl, array( 10006 - CURLOPT_URL => 'https://api.onecount.net/v2/resources', 10007 - CURLOPT_RETURNTRANSFER => true, 10008 - CURLOPT_ENCODING => '', 10009 - CURLOPT_MAXREDIRS => 10, 10010 - CURLOPT_TIMEOUT => 0, 10011 - CURLOPT_FOLLOWLOCATION => true, 10012 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10013 - CURLOPT_CUSTOMREQUEST => 'POST', 10014 - 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}', 10015 - CURLOPT_HTTPHEADER => array( 10016 - 'Appkey: {{ONECOUNT API KEY}}' 10017 - ), 10018 -)); 10019 - 10020 -$response = curl_exec($curl); 10021 - 10022 -curl_close($curl); 10023 -echo $response; 10024 -{{/code}} 10025 - 10026 10026 \\ 10027 10027 10028 -(% style="color: rgb(107,107,107);" %)Response 200 OK 10029 - 10030 -{{code language="yml" theme="RDark" title="Create Resource Response" collapse="true"}} 10031 - { 10032 - "result": { 10033 - "success": "1", 10034 - "error": { 10035 - "code": "", 10036 - "message": "" 10037 - } 10038 - }, 10039 - "Resources": [ 10040 - { 10041 - "Id": 871, 10042 - "Name": "Test API product creation 21", 10043 - "Description": "Test API product creation 21", 10044 - "Type": "3", 10045 - "Value": "http://one-count.com", 10046 - "FreePass": 1 10047 - } 10048 - ] 10049 -} 10050 -{{/code}} 10051 - 10052 10052 \\ 10053 10053 10054 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 10055 -== (% 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(%%) == 10056 - 10057 ----- 10058 - 10059 -{{panel bgColor="#D3D3D3" width="100%"}} 10060 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources/~{~{resource id}} 10061 -{{/panel}} 10062 - 10063 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 10064 - 10065 ----- 10066 - 10067 -(% 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}} 10068 - 10069 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 10070 - 10071 ----- 10072 - 10073 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 10074 -{"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} 10075 -{{/code}} 10076 - 10077 -==== Example ==== 10078 - 10079 ----- 10080 - 10081 -(% style="color: rgb(107,107,107);" %)Request 10082 - 10083 -{{code language="php" theme="RDark" title="Update Resource Request" collapse="true"}} 10084 - <?php 10085 - 10086 -$curl = curl_init(); 10087 - 10088 -curl_setopt_array($curl, array( 10089 - CURLOPT_URL => 'https://api.onecount.net/v2/resources/{{resource id}}', 10090 - CURLOPT_RETURNTRANSFER => true, 10091 - CURLOPT_ENCODING => '', 10092 - CURLOPT_MAXREDIRS => 10, 10093 - CURLOPT_TIMEOUT => 0, 10094 - CURLOPT_FOLLOWLOCATION => true, 10095 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10096 - CURLOPT_CUSTOMREQUEST => 'PUT', 10097 - 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}', 10098 - CURLOPT_HTTPHEADER => array( 10099 - 'Appkey: {{ONECOUNT API KEY}}' 10100 - ), 10101 -)); 10102 - 10103 -$response = curl_exec($curl); 10104 - 10105 -curl_close($curl); 10106 -echo $response; 10107 -{{/code}} 10108 - 10109 10109 \\ 10110 10110 10111 -(% style="color: rgb(107,107,107);" %)Response 200 OK 10112 - 10113 -{{code language="yml" theme="RDark" title="Update Resource Response" collapse="true"}} 10114 - { 10115 - "result": { 10116 - "success": "1", 10117 - "error": { 10118 - "code": "", 10119 - "message": "" 10120 - } 10121 - }, 10122 - "Resources": [ 10123 - { 10124 - "Id": 903, 10125 - "Name": "Test API product creation 23", 10126 - "Description": "Test API product creation 23", 10127 - "Type": "3", 10128 - "Value": "http://one-count.com", 10129 - "FreePass": 1 10130 - }, 10131 - { 10132 - "Id": 903, 10133 - "Name": "Test API product creation 23", 10134 - "Description": "Test API product creation 23", 10135 - "Type": "3", 10136 - "Value": "onecount.net", 10137 - "FreePass": 1 10138 - } 10139 - ] 10140 -} 10141 -{{/code}} 10142 - 10143 10143 (% class="western" %) 10144 10144 \\ 10145 10145 ... ... @@ -10248,7 +10248,7 @@ 10248 10248 $curl = curl_init(); 10249 10249 10250 10250 curl_setopt_array($curl, array( 10251 - CURLOPT_URL => ' https://api.onecount.net/v2/sources',9801 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/sources', 10252 10252 CURLOPT_RETURNTRANSFER => true, 10253 10253 CURLOPT_ENCODING => '', 10254 10254 CURLOPT_MAXREDIRS => 10, ... ... @@ -10464,7 +10464,7 @@ 10464 10464 $curl = curl_init(); 10465 10465 10466 10466 curl_setopt_array($curl, array( 10467 - CURLOPT_URL => ' https://api.onecount.net/v2/sources/{{source code id}}',10017 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/sources/{{source code id}}', 10468 10468 CURLOPT_RETURNTRANSFER => true, 10469 10469 CURLOPT_ENCODING => '', 10470 10470 CURLOPT_MAXREDIRS => 10, ... ... @@ -10515,7 +10515,7 @@ 10515 10515 ---- 10516 10516 10517 10517 {{panel bgColor="#D3D3D3" width="100%"}} 10518 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/ sources/lookup?Source={(%%){Source code Name}}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,4 10519 10519 {{/panel}} 10520 10520 10521 10521 === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === ... ... @@ -10528,7 +10528,8 @@ 10528 10528 10529 10529 ---- 10530 10530 10531 -(% 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}} 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 10532 10532 10533 10533 ==== Example ==== 10534 10534 ... ... @@ -10536,217 +10536,22 @@ 10536 10536 10537 10537 (% style="color: rgb(107,107,107);" %)Request 10538 10538 10539 -{{code language="php" theme="RDark" title="Lookup Source code Request" collapse="true"}} 10540 - <?php 10090 +{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}} 10541 10541 10542 -$curl = curl_init(); 10543 - 10544 -curl_setopt_array($curl, array( 10545 - CURLOPT_URL => 'https://api.onecount.net/v2/sources/lookup?Source={{Source code Name}}', 10546 - CURLOPT_RETURNTRANSFER => true, 10547 - CURLOPT_ENCODING => '', 10548 - CURLOPT_MAXREDIRS => 10, 10549 - CURLOPT_TIMEOUT => 0, 10550 - CURLOPT_FOLLOWLOCATION => true, 10551 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10552 - CURLOPT_CUSTOMREQUEST => 'GET', 10553 - CURLOPT_HTTPHEADER => array( 10554 - 'Appkey: {{ONECOUNT API KEY}}' 10555 - ), 10556 -)); 10557 - 10558 -$response = curl_exec($curl); 10559 - 10560 -curl_close($curl); 10561 -echo $response; 10562 -{{/code}} 10563 - 10564 10564 \\ 10565 10565 10566 10566 (% style="color: rgb(107,107,107);" %)Response 200 OK 10567 10567 10568 -{{code language="yml" theme="RDark" title="Lookup Source code Response" collapse="true"}} 10569 - { 10570 - "result": { 10571 - "success": "1", 10572 - "error": { 10573 - "code": "", 10574 - "message": "" 10575 - } 10576 - }, 10577 - "Sources": [ 10578 - { 10579 - "Id": 26, 10580 - "Source": "GCN-Member", 10581 - "Description": "Uploaded from Reston VA", 10582 - "Parent": 0 10583 - } 10584 - ] 10585 -} 10586 -{{/code}} 10096 +{{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"/}} 10587 10587 10588 10588 \\ 10589 10589 10590 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 10591 -== (% 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(%%) == 10592 - 10593 ----- 10594 - 10595 -{{panel bgColor="#D3D3D3" width="100%"}} 10596 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/sources 10597 -{{/panel}} 10598 - 10599 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 10600 - 10601 ----- 10602 - 10603 -(% 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}} 10604 - 10605 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 10606 - 10607 ----- 10608 - 10609 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 10610 -{"Source":"Test source code from API"} 10611 -{{/code}} 10612 - 10613 -==== Example ==== 10614 - 10615 ----- 10616 - 10617 -(% style="color: rgb(107,107,107);" %)Request 10618 - 10619 -{{code language="php" theme="RDark" title="Create Source code Request" collapse="true"}} 10620 - <?php 10621 - 10622 -$curl = curl_init(); 10623 - 10624 -curl_setopt_array($curl, array( 10625 - CURLOPT_URL => 'https://api.onecount.net/v2/sources', 10626 - CURLOPT_RETURNTRANSFER => true, 10627 - CURLOPT_ENCODING => '', 10628 - CURLOPT_MAXREDIRS => 10, 10629 - CURLOPT_TIMEOUT => 0, 10630 - CURLOPT_FOLLOWLOCATION => true, 10631 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10632 - CURLOPT_CUSTOMREQUEST => 'POST', 10633 - CURLOPT_POSTFIELDS =>'{"Source":"Test source code from API"}', 10634 - CURLOPT_HTTPHEADER => array( 10635 - 'Appkey: {{ONECOUNT API KEY}}' 10636 - ), 10637 -)); 10638 - 10639 -$response = curl_exec($curl); 10640 - 10641 -curl_close($curl); 10642 -echo $response; 10643 -{{/code}} 10644 - 10645 10645 \\ 10646 10646 10647 -(% style="color: rgb(107,107,107);" %)Response 200 OK 10648 - 10649 -{{code language="yml" theme="RDark" title="Create Source code Response" collapse="true"}} 10650 - { 10651 - "result": { 10652 - "success": "1", 10653 - "error": { 10654 - "code": "", 10655 - "message": "" 10656 - } 10657 - }, 10658 - "Sources": [ 10659 - { 10660 - "Id": 223, 10661 - "Source": "Test source code from API", 10662 - "Description": "", 10663 - "Parent": 0 10664 - } 10665 - ] 10666 -} 10667 -{{/code}} 10668 - 10669 10669 \\ 10670 10670 10671 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 10672 -== (% 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(%%) == 10673 - 10674 ----- 10675 - 10676 -{{panel bgColor="#D3D3D3" width="100%"}} 10677 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/sources/~{~{source code id}} 10678 -{{/panel}} 10679 - 10680 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 10681 - 10682 ----- 10683 - 10684 -(% 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}} 10685 - 10686 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 10687 - 10688 ----- 10689 - 10690 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 10691 -{"Source":"Test API","Parent":215} 10692 -{{/code}} 10693 - 10694 -==== Example ==== 10695 - 10696 ----- 10697 - 10698 -(% style="color: rgb(107,107,107);" %)Request 10699 - 10700 -{{code language="php" theme="RDark" title="Update Source code Request" collapse="true"}} 10701 - <?php 10702 - 10703 -$curl = curl_init(); 10704 - 10705 -curl_setopt_array($curl, array( 10706 - CURLOPT_URL => 'https://api.onecount.net/v2/sources/{{source code id}}', 10707 - CURLOPT_RETURNTRANSFER => true, 10708 - CURLOPT_ENCODING => '', 10709 - CURLOPT_MAXREDIRS => 10, 10710 - CURLOPT_TIMEOUT => 0, 10711 - CURLOPT_FOLLOWLOCATION => true, 10712 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 10713 - CURLOPT_CUSTOMREQUEST => 'PUT', 10714 - CURLOPT_POSTFIELDS =>'{"Source":"Test API","Parent":215}', 10715 - CURLOPT_HTTPHEADER => array( 10716 - 'Appkey: {{ONECOUNT API KEY}}' 10717 - ), 10718 -)); 10719 - 10720 -$response = curl_exec($curl); 10721 - 10722 -curl_close($curl); 10723 -echo $response; 10724 -{{/code}} 10725 - 10726 10726 \\ 10727 10727 10728 -(% style="color: rgb(107,107,107);" %)Response 200 OK 10729 - 10730 -{{code language="yml" theme="RDark" title="Update Source code Response" collapse="true"}} 10731 - { 10732 - "result": { 10733 - "success": "1", 10734 - "error": { 10735 - "code": "", 10736 - "message": "" 10737 - } 10738 - }, 10739 - "Sources": [ 10740 - { 10741 - "Id": 223, 10742 - "Source": "Test API", 10743 - "Description": "", 10744 - "Parent": 215 10745 - } 10746 - ] 10747 -} 10748 -{{/code}} 10749 - 10750 10750 (% class="western" %) 10751 10751 \\ 10752 10752 ... ... @@ -10841,7 +10841,7 @@ 10841 10841 $curl = curl_init(); 10842 10842 10843 10843 curl_setopt_array($curl, array( 10844 - CURLOPT_URL => ' https://api.onecount.net/v2/transactions',10200 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/transactions?limit=100', 10845 10845 CURLOPT_RETURNTRANSFER => true, 10846 10846 CURLOPT_ENCODING => '', 10847 10847 CURLOPT_MAXREDIRS => 10, ... ... @@ -12407,7 +12407,7 @@ 12407 12407 $curl = curl_init(); 12408 12408 12409 12409 curl_setopt_array($curl, array( 12410 - CURLOPT_URL => ' https://api.onecount.net/v2/transactions/{{Transaction id}}',11766 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/transactions/{{Transaction id}}', 12411 12411 CURLOPT_RETURNTRANSFER => true, 12412 12412 CURLOPT_ENCODING => '', 12413 12413 CURLOPT_MAXREDIRS => 10, ... ... @@ -12467,7 +12467,7 @@ 12467 12467 ---- 12468 12468 12469 12469 {{panel bgColor="#D3D3D3" width="100%"}} 12470 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/ transactions/lookup?UserId=~{~{OCID}}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,4 12471 12471 {{/panel}} 12472 12472 12473 12473 === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === ... ... @@ -12480,7 +12480,8 @@ 12480 12480 12481 12481 ---- 12482 12482 12483 -(% 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}} 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 12484 12484 12485 12485 ==== Example ==== 12486 12486 ... ... @@ -12488,328 +12488,18 @@ 12488 12488 12489 12489 (% style="color: rgb(107,107,107);" %)Request 12490 12490 12491 -{{code language="php" theme="RDark" title="Lookup Transaction Request" collapse="true"}} 12492 - <?php 11848 +{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}} 12493 12493 12494 -$curl = curl_init(); 12495 - 12496 -curl_setopt_array($curl, array( 12497 - CURLOPT_URL => 'https://api.onecount.net/v2/transactions/lookup?UserId={{OCID}}', 12498 - CURLOPT_RETURNTRANSFER => true, 12499 - CURLOPT_ENCODING => '', 12500 - CURLOPT_MAXREDIRS => 10, 12501 - CURLOPT_TIMEOUT => 0, 12502 - CURLOPT_FOLLOWLOCATION => true, 12503 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 12504 - CURLOPT_CUSTOMREQUEST => 'GET', 12505 - CURLOPT_HTTPHEADER => array( 12506 - 'Appkey: {{ONECOUNT API KEY}}' 12507 - ), 12508 -)); 12509 - 12510 -$response = curl_exec($curl); 12511 - 12512 -curl_close($curl); 12513 -echo $response; 12514 -{{/code}} 12515 - 12516 12516 \\ 12517 12517 12518 12518 (% style="color: rgb(107,107,107);" %)Response 200 OK 12519 12519 12520 -{{code language="yml" theme="RDark" title="Lookup Transaction Response" collapse="true"}} 12521 - { 12522 - "result": { 12523 - "success": "1", 12524 - "error": { 12525 - "code": "", 12526 - "message": "" 12527 - } 12528 - }, 12529 - "Transactions": [ 12530 - { 12531 - "Id": 52494786, 12532 - "UserId": 1234, 12533 - "TermId": 34, 12534 - "TransactionDate": "2016-01-19", 12535 - "TransactionTime": "15:30:04", 12536 - "RequestDate": "2016-01-19", 12537 - "UserIP": "12.226.247.2", 12538 - "SubscriptionType": "u", 12539 - "ProductId": 34, 12540 - "Source": 0, 12541 - "ProductStatus": 0, 12542 - "MediaFilePath": "", 12543 - "Amount": "" 12544 - }, 12545 - { 12546 - "Id": 42654041, 12547 - "UserId": 1234, 12548 - "TermId": 34, 12549 - "TransactionDate": "2015-09-09", 12550 - "TransactionTime": "11:20:39", 12551 - "RequestDate": "2015-09-09", 12552 - "UserIP": "24.187.236.98", 12553 - "SubscriptionType": "n", 12554 - "ProductId": 34, 12555 - "Source": 0, 12556 - "ProductStatus": 2, 12557 - "MediaFilePath": "", 12558 - "Amount": "" 12559 - }, 12560 - { 12561 - "Id": 97251022, 12562 - "UserId": 1234, 12563 - "TermId": 34, 12564 - "TransactionDate": "2015-06-04", 12565 - "TransactionTime": "14:59:42", 12566 - "RequestDate": "2015-06-04", 12567 - "UserIP": "12.226.247.2", 12568 - "SubscriptionType": "u", 12569 - "ProductId": 34, 12570 - "Source": 0, 12571 - "ProductStatus": 0, 12572 - "MediaFilePath": "", 12573 - "Amount": "" 12574 - }, 12575 - { 12576 - "Id": 55492559, 12577 - "UserId": 1234, 12578 - "TermId": 34, 12579 - "TransactionDate": "2015-04-03", 12580 - "TransactionTime": "16:32:04", 12581 - "RequestDate": "2015-04-03", 12582 - "UserIP": "24.187.236.98", 12583 - "SubscriptionType": "r", 12584 - "ProductId": 34, 12585 - "Source": 58, 12586 - "ProductStatus": 106, 12587 - "MediaFilePath": "", 12588 - "Amount": "" 12589 - }, 12590 - { 12591 - "Id": 98173391, 12592 - "UserId": 1234, 12593 - "TermId": 34, 12594 - "TransactionDate": "2015-04-03", 12595 - "TransactionTime": "15:50:45", 12596 - "RequestDate": "2014-08-19", 12597 - "UserIP": "24.187.236.98", 12598 - "SubscriptionType": "n", 12599 - "ProductId": 34, 12600 - "Source": 34, 12601 - "ProductStatus": 106, 12602 - "MediaFilePath": "", 12603 - "Amount": "" 12604 - }, 12605 - { 12606 - "Id": 91711793, 12607 - "UserId": 1234, 12608 - "TermId": 18, 12609 - "TransactionDate": "2015-04-27", 12610 - "TransactionTime": "14:24:51", 12611 - "RequestDate": "2015-04-27", 12612 - "UserIP": "24.187.236.98", 12613 - "SubscriptionType": "u", 12614 - "ProductId": 18, 12615 - "Source": 0, 12616 - "ProductStatus": 106, 12617 - "MediaFilePath": "", 12618 - "Amount": "" 12619 - }, 12620 - { 12621 - "Id": 74936400, 12622 - "UserId": 1234, 12623 - "TermId": 18, 12624 - "TransactionDate": "2015-04-27", 12625 - "TransactionTime": "12:35:18", 12626 - "RequestDate": "2015-04-27", 12627 - "UserIP": "68.196.187.74", 12628 - "SubscriptionType": "n", 12629 - "ProductId": 18, 12630 - "Source": 34, 12631 - "ProductStatus": 106, 12632 - "MediaFilePath": "", 12633 - "Amount": "" 12634 - }, 12635 - { 12636 - "Id": 21664714, 12637 - "UserId": 1234, 12638 - "TermId": 18, 12639 - "TransactionDate": "2015-04-03", 12640 - "TransactionTime": "15:50:46", 12641 - "RequestDate": "2015-04-03", 12642 - "UserIP": "24.187.236.98", 12643 - "SubscriptionType": "u", 12644 - "ProductId": 18, 12645 - "Source": 0, 12646 - "ProductStatus": 2, 12647 - "MediaFilePath": "", 12648 - "Amount": "" 12649 - }, 12650 - { 12651 - "Id": 81129263, 12652 - "UserId": 1234, 12653 - "TermId": 18, 12654 - "TransactionDate": "2014-08-19", 12655 - "TransactionTime": "11:18:55", 12656 - "RequestDate": "2014-08-19", 12657 - "UserIP": "74.201.38.1", 12658 - "SubscriptionType": "n", 12659 - "ProductId": 18, 12660 - "Source": 34, 12661 - "ProductStatus": 2, 12662 - "MediaFilePath": "", 12663 - "Amount": "" 12664 - }, 12665 - { 12666 - "Id": 30461748, 12667 - "UserId": 1234, 12668 - "ResourceId": 459, 12669 - "TransactionDate": "2023-03-15", 12670 - "TransactionTime": "12:07:55", 12671 - "RequestDate": "2023-03-15", 12672 - "UserIP": "74.201.38.12", 12673 - "SubscriptionType": "n", 12674 - "SourceCode": 0, 12675 - "ProductStatus": 0, 12676 - "MediaFilePath": "", 12677 - "Amount": "" 12678 - }, 12679 - { 12680 - "Id": 25858253, 12681 - "UserId": 1234, 12682 - "ResourceId": 451, 12683 - "TransactionDate": "2023-03-15", 12684 - "TransactionTime": "11:45:19", 12685 - "RequestDate": "2023-03-15", 12686 - "UserIP": "74.201.38.12", 12687 - "SubscriptionType": "n", 12688 - "SourceCode": 0, 12689 - "ProductStatus": 0, 12690 - "MediaFilePath": "", 12691 - "Amount": "" 12692 - }, 12693 - { 12694 - "Id": 69453260, 12695 - "UserId": 1234, 12696 - "ResourceId": 411, 12697 - "TransactionDate": "2022-06-07", 12698 - "TransactionTime": "17:03:14", 12699 - "RequestDate": "2022-06-07", 12700 - "UserIP": "74.201.38.12", 12701 - "SubscriptionType": "n", 12702 - "SourceCode": 0, 12703 - "ProductStatus": 0, 12704 - "MediaFilePath": "", 12705 - "Amount": "" 12706 - }, 12707 - { 12708 - "Id": 51354425, 12709 - "UserId": 1234, 12710 - "ResourceId": 355, 12711 - "TransactionDate": "2020-04-06", 12712 - "TransactionTime": "12:24:08", 12713 - "RequestDate": "2020-04-06", 12714 - "UserIP": "74.201.38.12", 12715 - "SubscriptionType": "n", 12716 - "SourceCode": 0, 12717 - "ProductStatus": 0, 12718 - "MediaFilePath": "", 12719 - "Amount": "" 12720 - } 12721 - ] 12722 -} 12723 -{{/code}} 11854 +{{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"/}} 12724 12724 12725 12725 \\ 12726 12726 12727 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %) 12728 -== (% 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(%%) == 12729 - 12730 ----- 12731 - 12732 -{{panel bgColor="#D3D3D3" width="100%"}} 12733 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/transactions 12734 -{{/panel}} 12735 - 12736 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) === 12737 - 12738 ----- 12739 - 12740 -(% 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}} 12741 - 12742 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) === 12743 - 12744 ----- 12745 - 12746 -{{code language="yml" theme="RDark" title="Body" collapse="true"}} 12747 -{"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" } 12748 -{{/code}} 12749 - 12750 -==== Example ==== 12751 - 12752 ----- 12753 - 12754 -(% style="color: rgb(107,107,107);" %)Request 12755 - 12756 -{{code language="php" theme="RDark" title="Create Transaction Request" collapse="true"}} 12757 - <?php 12758 - 12759 -$curl = curl_init(); 12760 - 12761 -curl_setopt_array($curl, array( 12762 - CURLOPT_URL => 'https://api.onecount.net/v2/transactions', 12763 - CURLOPT_RETURNTRANSFER => true, 12764 - CURLOPT_ENCODING => '', 12765 - CURLOPT_MAXREDIRS => 10, 12766 - CURLOPT_TIMEOUT => 0, 12767 - CURLOPT_FOLLOWLOCATION => true, 12768 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 12769 - CURLOPT_CUSTOMREQUEST => 'POST', 12770 - 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" }', 12771 - CURLOPT_HTTPHEADER => array( 12772 - 'Appkey: {{ONECOUNT API KEY}}' 12773 - ), 12774 -)); 12775 - 12776 -$response = curl_exec($curl); 12777 - 12778 -curl_close($curl); 12779 -echo $response; 12780 -{{/code}} 12781 - 12782 12782 \\ 12783 12783 12784 -(% style="color: rgb(107,107,107);" %)Response 200 OK 12785 - 12786 -{{code language="yml" theme="RDark" title="Create Transaction Response" collapse="true"}} 12787 - { 12788 - "result": { 12789 - "success": "1", 12790 - "error": { 12791 - "code": "", 12792 - "message": "" 12793 - } 12794 - }, 12795 - "Transactions": { 12796 - "Id": "1234", 12797 - "UserId": 1845775, 12798 - "TermId": 447, 12799 - "TransactionDate": "20231211", 12800 - "TransactionTime": "09:34:26", 12801 - "RequestDate": "20231211", 12802 - "UserIP": "192.168.0.1", 12803 - "SubscriptionType": "n", 12804 - "ProductId": 599, 12805 - "Source": 83, 12806 - "ProductStatus": 2, 12807 - "MediaFilePath": "", 12808 - "Amount": "0.00" 12809 - } 12810 -} 12811 -{{/code}} 12812 - 12813 12813 \\ 12814 12814 12815 12815 \\ ... ... @@ -12854,12 +12854,6 @@ 12854 12854 12855 12855 \\ 12856 12856 12857 -\\ 12858 - 12859 -\\ 12860 - 12861 -\\ 12862 - 12863 12863 (% class="western" %) 12864 12864 **COMPONENT: Leads 12865 12865 **
- Confluence.Code.ConfluencePageClass[0]
-
- id
-
... ... @@ -1,1 +1,1 @@ 1 -10826548 31 +108265481 - url
-
... ... @@ -1,1 +1,1 @@ 1 -https://info.onecount.net//wiki/spaces/OD/pages/10826548 3/ONEcount API Documentation1 +https://info.onecount.net//wiki/spaces/OD/pages/108265481/ONEcount API Documentation