Last modified by Rayaan Ahmed on 2025/02/09 22:20

From version 5.1
edited by rayaan@one-count_com
on 2023/12/12 07:43
Change comment: There is no comment for this version
To version 3.1
edited by rayaan@one-count_com
on 2023/12/12 06:21
Change comment: There is no comment for this version

Summary

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 CSV of 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,
... ... @@ -1474,7 +1474,7 @@
1474 1474  \\
1475 1475  
1476 1476  (% class="western" %)
1477 -=== **COMPONENT: Questions** ===
1473 +**COMPONENT: Questions**
1478 1478  
1479 1479  (% class="western" %)
1480 1480  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).
... ... @@ -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,
... ... @@ -8246,7 +8246,7 @@
8246 8246  \\
8247 8247  
8248 8248  (% class="western" %)
8249 -=== **COMPONENT: Products** ===
8245 +**COMPONENT: Products**
8250 8250  
8251 8251  (% class="western" %)
8252 8252  This resource is for manipulating products resource. A product can be created, updated or searched.
... ... @@ -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={{Product Name}}',
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,239 +8815,106 @@
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);" %)Request
8836 +\\
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 OK
8850 +\\
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);" %)Request
8878 +\\
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 OK
8892 +\\
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  
8977 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
8978 -== (% 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(%%) ==
8898 +\\
8979 8979  
8980 -----
8900 +\\
8981 8981  
8982 -{{panel bgColor="#D3D3D3" width="100%"}}
8983 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/products/attachResource
8984 -{{/panel}}
8902 +\\
8985 8985  
8986 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
8904 +\\
8987 8987  
8988 -----
8906 +\\
8989 8989  
8990 -(% 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}}
8908 +\\
8991 8991  
8992 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
8993 -
8994 -----
8995 -
8996 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
8997 -{"ProductID":"599","ResourceID":"903"}
8998 -{{/code}}
8999 -
9000 -==== Example ====
9001 -
9002 -----
9003 -
9004 -(% style="color: rgb(107,107,107);" %)Request
9005 -
9006 -{{code language="php" theme="RDark" title="Attach Resource to Product Request" collapse="true"}}
9007 - <?php
9008 -
9009 -$curl = curl_init();
9010 -
9011 -curl_setopt_array($curl, array(
9012 - CURLOPT_URL => 'https://api.onecount.net/v2/products/attachResource',
9013 - CURLOPT_RETURNTRANSFER => true,
9014 - CURLOPT_ENCODING => '',
9015 - CURLOPT_MAXREDIRS => 10,
9016 - CURLOPT_TIMEOUT => 0,
9017 - CURLOPT_FOLLOWLOCATION => true,
9018 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
9019 - CURLOPT_CUSTOMREQUEST => 'POST',
9020 - CURLOPT_POSTFIELDS =>'{"ProductID":"599","ResourceID":"903"}',
9021 - CURLOPT_HTTPHEADER => array(
9022 - 'Appkey: {{ONECOUNT API KEY}}'
9023 - ),
9024 -));
9025 -
9026 -$response = curl_exec($curl);
9027 -
9028 -curl_close($curl);
9029 -echo $response;
9030 -{{/code}}
9031 -
9032 9032  \\
9033 9033  
9034 -(% style="color: rgb(107,107,107);" %)Response  200 OK
9035 -
9036 -{{code language="yml" theme="RDark" title="Create Product Response" collapse="true"}}
9037 - {
9038 - "result": {
9039 - "success": "1",
9040 - "error": {
9041 - "code": "",
9042 - "message": ""
9043 - }
9044 - },
9045 - "Products": "599"
9046 -}
9047 -{{/code}}
9048 -
9049 9049  (% class="western" %)
9050 -=== **COMPONENT: Terms** ===
8913 +**COMPONENT: Terms**
9051 9051  
9052 9052  (% class="western" %)
9053 9053  This resource is for manipulating terms resource. A term can be created, updated or searched.
... ... @@ -9150,7 +9150,7 @@
9150 9150  $curl = curl_init();
9151 9151  
9152 9152  curl_setopt_array($curl, array(
9153 - CURLOPT_URL => 'https://api.onecount.net/v2/terms',
9016 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/terms',
9154 9154   CURLOPT_RETURNTRANSFER => true,
9155 9155   CURLOPT_ENCODING => '',
9156 9156   CURLOPT_MAXREDIRS => 10,
... ... @@ -9333,7 +9333,7 @@
9333 9333  $curl = curl_init();
9334 9334  
9335 9335  curl_setopt_array($curl, array(
9336 - CURLOPT_URL => 'https://api.onecount.net/v2/terms/{{Term Id}}',
9199 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/terms/{{Term Id}}',
9337 9337   CURLOPT_RETURNTRANSFER => true,
9338 9338   CURLOPT_ENCODING => '',
9339 9339   CURLOPT_MAXREDIRS => 10,
... ... @@ -9414,7 +9414,7 @@
9414 9414  $curl = curl_init();
9415 9415  
9416 9416  curl_setopt_array($curl, array(
9417 - 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}} ',
9418 9418   CURLOPT_RETURNTRANSFER => true,
9419 9419   CURLOPT_ENCODING => '',
9420 9420   CURLOPT_MAXREDIRS => 10,
... ... @@ -9437,199 +9437,20 @@
9437 9437  
9438 9438  (% style="color: rgb(107,107,107);" %)Response  200 OK
9439 9439  
9440 -{{code language="yml" theme="RDark" title="Lookup Term Response" collapse="true"}}
9441 -{
9442 - "result": {
9443 - "success": "1",
9444 - "error": {
9445 - "code": "",
9446 - "message": ""
9447 - }
9448 - },
9449 - "Terms": [
9450 - {
9451 - "Id": 431,
9452 - "Name": "Test term for API 1",
9453 - "Description": null,
9454 - "Duration": 0,
9455 - "DurationUnit": "",
9456 - "Price": "0.00",
9457 - "ProductId": 599
9458 - }
9459 - ]
9460 -}
9461 -{{/code}}
9303 +{{code language="yml" theme="RDark" title="Lookup Term Response" collapse="true"/}}
9462 9462  
9463 9463  \\
9464 9464  
9465 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
9466 -== (% 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(%%) ==
9467 -
9468 -----
9469 -
9470 -{{panel bgColor="#D3D3D3" width="100%"}}
9471 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/terms
9472 -{{/panel}}
9473 -
9474 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
9475 -
9476 -----
9477 -
9478 -(% 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}}
9479 -
9480 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
9481 -
9482 -----
9483 -
9484 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
9485 -{"Name":"Test API term creation","Description":"Test API term creation","Duration":10,"ProductId":599}
9486 -{{/code}}
9487 -
9488 -==== Example ====
9489 -
9490 -----
9491 -
9492 -(% style="color: rgb(107,107,107);" %)Request
9493 -
9494 -{{code language="php" theme="RDark" title="Create Term Request" collapse="true"}}
9495 -<?php
9496 -
9497 -$curl = curl_init();
9498 -
9499 -curl_setopt_array($curl, array(
9500 - CURLOPT_URL => 'https://api.onecount.net/v2/terms',
9501 - CURLOPT_RETURNTRANSFER => true,
9502 - CURLOPT_ENCODING => '',
9503 - CURLOPT_MAXREDIRS => 10,
9504 - CURLOPT_TIMEOUT => 0,
9505 - CURLOPT_FOLLOWLOCATION => true,
9506 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
9507 - CURLOPT_CUSTOMREQUEST => 'POST',
9508 - CURLOPT_POSTFIELDS =>'{"Name":"Test API term creation","Description":"Test API term creation","Duration":10,"ProductId":599}
9509 -
9510 -',
9511 - CURLOPT_HTTPHEADER => array(
9512 - 'Appkey: {{ONECOUNT API KEY}}'
9513 - ),
9514 -));
9515 -
9516 -$response = curl_exec($curl);
9517 -
9518 -curl_close($curl);
9519 -echo $response;
9520 -
9521 -
9522 -{{/code}}
9523 -
9524 9524  \\
9525 9525  
9526 -(% style="color: rgb(107,107,107);" %)Response  200 OK
9527 -
9528 -{{code language="yml" theme="RDark" title="Create Term Response" collapse="true"}}
9529 -{
9530 - "result": {
9531 - "success": "1",
9532 - "error": {
9533 - "code": "",
9534 - "message": ""
9535 - }
9536 - },
9537 - "Terms": [
9538 - {
9539 - "Id": 447
9540 - }
9541 - ]
9542 -}
9543 -{{/code}}
9544 -
9545 9545  \\
9546 9546  
9547 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
9548 -== (% 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(%%) ==
9549 -
9550 -----
9551 -
9552 -{{panel bgColor="#D3D3D3" width="100%"}}
9553 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/terms/~{~{Term Id}}
9554 -{{/panel}}
9555 -
9556 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
9557 -
9558 -----
9559 -
9560 -(% 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}}
9561 -
9562 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
9563 -
9564 -----
9565 -
9566 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
9567 -{"Name":"Test API term creation update","Description":"Test API term creation update","Duration":10,"ProductId":599}
9568 -{{/code}}
9569 -
9570 -==== Example ====
9571 -
9572 -----
9573 -
9574 -(% style="color: rgb(107,107,107);" %)Request
9575 -
9576 -{{code language="php" theme="RDark" title="Update Term Request" collapse="true"}}
9577 - <?php
9578 -
9579 -$curl = curl_init();
9580 -
9581 -curl_setopt_array($curl, array(
9582 - CURLOPT_URL => 'https://api.onecount.net/v2/terms/{{Term Id}}',
9583 - CURLOPT_RETURNTRANSFER => true,
9584 - CURLOPT_ENCODING => '',
9585 - CURLOPT_MAXREDIRS => 10,
9586 - CURLOPT_TIMEOUT => 0,
9587 - CURLOPT_FOLLOWLOCATION => true,
9588 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
9589 - CURLOPT_CUSTOMREQUEST => 'PUT',
9590 - CURLOPT_POSTFIELDS =>'{"Name":"Test API term creation update","Description":"Test API term creation update","Duration":10,"ProductId":599}',
9591 - CURLOPT_HTTPHEADER => array(
9592 - 'Appkey: {{ONECOUNT API KEY}}'
9593 - ),
9594 -));
9595 -
9596 -$response = curl_exec($curl);
9597 -
9598 -curl_close($curl);
9599 -echo $response;
9600 -{{/code}}
9601 -
9602 9602  \\
9603 9603  
9604 -(% style="color: rgb(107,107,107);" %)Response  200 OK
9605 -
9606 -{{code language="yml" theme="RDark" title="Update Term Response" collapse="true"}}
9607 - {
9608 - "result": {
9609 - "success": "1",
9610 - "error": {
9611 - "code": "",
9612 - "message": ""
9613 - }
9614 - },
9615 - "Terms": [
9616 - {
9617 - "Id": 447,
9618 - "Name": "Test API term creation update",
9619 - "Description": "Test API term creation update",
9620 - "Duration": 10,
9621 - "DurationUnit": "",
9622 - "Price": "0.00",
9623 - "ProductId": 599
9624 - }
9625 - ]
9626 -}
9627 -{{/code}}
9628 -
9629 9629  \\
9630 9630  
9631 9631  (% class="western" %)
9632 -=== **COMPONENT: Resources** ===
9316 +**COMPONENT: Resources**
9633 9633  
9634 9634  (% class="western" %)
9635 9635  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.
... ... @@ -9767,7 +9767,7 @@
9767 9767  $curl = curl_init();
9768 9768  
9769 9769  curl_setopt_array($curl, array(
9770 - CURLOPT_URL => 'https://api.onecount.net/v2/resources',
9454 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/resources?limit=10',
9771 9771   CURLOPT_RETURNTRANSFER => true,
9772 9772   CURLOPT_ENCODING => '',
9773 9773   CURLOPT_MAXREDIRS => 10,
... ... @@ -9913,7 +9913,7 @@
9913 9913  $curl = curl_init();
9914 9914  
9915 9915  curl_setopt_array($curl, array(
9916 - CURLOPT_URL => 'https://api.onecount.net/v2/resources/{{Resource ID}}',
9600 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/resources/{{Resource ID}}',
9917 9917   CURLOPT_RETURNTRANSFER => true,
9918 9918   CURLOPT_ENCODING => '',
9919 9919   CURLOPT_MAXREDIRS => 10,
... ... @@ -9966,7 +9966,7 @@
9966 9966  ----
9967 9967  
9968 9968  {{panel bgColor="#D3D3D3" width="100%"}}
9969 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources/lookup?Name={(%%){Resource Name}}
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
9970 9970  {{/panel}}
9971 9971  
9972 9972  === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
... ... @@ -9979,7 +9979,8 @@
9979 9979  
9980 9980  ----
9981 9981  
9982 -(% 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
9983 9983  
9984 9984  ==== Example ====
9985 9985  
... ... @@ -9987,237 +9987,30 @@
9987 9987  
9988 9988  (% style="color: rgb(107,107,107);" %)Request
9989 9989  
9990 -{{code language="php" theme="RDark" title="Lookup Resource Request" collapse="true"}}
9991 - <?php
9675 +{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}}
9992 9992  
9993 -$curl = curl_init();
9994 -
9995 -curl_setopt_array($curl, array(
9996 - CURLOPT_URL => 'https://api.onecount.net/v2/resources/lookup?Name={{Resource Name}}',
9997 - CURLOPT_RETURNTRANSFER => true,
9998 - CURLOPT_ENCODING => '',
9999 - CURLOPT_MAXREDIRS => 10,
10000 - CURLOPT_TIMEOUT => 0,
10001 - CURLOPT_FOLLOWLOCATION => true,
10002 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
10003 - CURLOPT_CUSTOMREQUEST => 'GET',
10004 - CURLOPT_HTTPHEADER => array(
10005 - 'Appkey: {{ONECOUNT API KEY}}'
10006 - ),
10007 -));
10008 -
10009 -$response = curl_exec($curl);
10010 -
10011 -curl_close($curl);
10012 -echo $response;
10013 -{{/code}}
10014 -
10015 10015  \\
10016 10016  
10017 10017  (% style="color: rgb(107,107,107);" %)Response  200 OK
10018 10018  
10019 -{{code language="yml" theme="RDark" title="Lookup Resource Response" collapse="true"}}
10020 - {
10021 - "result": {
10022 - "success": "1",
10023 - "error": {
10024 - "code": "",
10025 - "message": ""
10026 - }
10027 - },
10028 - "Resources": [
10029 - {
10030 - "Id": 479,
10031 - "Name": "Virtualization Review",
10032 - "Description": "",
10033 - "Type": "0",
10034 - "Value": "",
10035 - "FreePass": 0
10036 - }
10037 - ]
10038 -}
10039 -{{/code}}
9681 +{{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"/}}
10040 10040  
10041 10041  \\
10042 10042  
10043 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
10044 -== (% 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 +\\
10045 10045  
10046 -----
10047 -
10048 -{{panel bgColor="#D3D3D3" width="100%"}}
10049 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources
10050 -{{/panel}}
10051 -
10052 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
10053 -
10054 -----
10055 -
10056 -(% 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}}
10057 -
10058 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
10059 -
10060 -----
10061 -
10062 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
10063 -{"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}
10064 -{{/code}}
10065 -
10066 -==== Example ====
10067 -
10068 -----
10069 -
10070 -(% style="color: rgb(107,107,107);" %)Request
10071 -
10072 -{{code language="php" theme="RDark" title="Create Resource Request" collapse="true"}}
10073 - <?php
10074 -
10075 -$curl = curl_init();
10076 -
10077 -curl_setopt_array($curl, array(
10078 - CURLOPT_URL => 'https://api.onecount.net/v2/resources',
10079 - CURLOPT_RETURNTRANSFER => true,
10080 - CURLOPT_ENCODING => '',
10081 - CURLOPT_MAXREDIRS => 10,
10082 - CURLOPT_TIMEOUT => 0,
10083 - CURLOPT_FOLLOWLOCATION => true,
10084 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
10085 - CURLOPT_CUSTOMREQUEST => 'POST',
10086 - 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}',
10087 - CURLOPT_HTTPHEADER => array(
10088 - 'Appkey: {{ONECOUNT API KEY}}'
10089 - ),
10090 -));
10091 -
10092 -$response = curl_exec($curl);
10093 -
10094 -curl_close($curl);
10095 -echo $response;
10096 -{{/code}}
10097 -
10098 10098  \\
10099 10099  
10100 -(% style="color: rgb(107,107,107);" %)Response  200 OK
10101 -
10102 -{{code language="yml" theme="RDark" title="Create Resource Response" collapse="true"}}
10103 - {
10104 - "result": {
10105 - "success": "1",
10106 - "error": {
10107 - "code": "",
10108 - "message": ""
10109 - }
10110 - },
10111 - "Resources": [
10112 - {
10113 - "Id": 871,
10114 - "Name": "Test API product creation 21",
10115 - "Description": "Test API product creation 21",
10116 - "Type": "3",
10117 - "Value": "http://one-count.com",
10118 - "FreePass": 1
10119 - }
10120 - ]
10121 -}
10122 -{{/code}}
10123 -
10124 10124  \\
10125 10125  
10126 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
10127 -== (% 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(%%) ==
10128 -
10129 -----
10130 -
10131 -{{panel bgColor="#D3D3D3" width="100%"}}
10132 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/resources/~{~{resource id}}
10133 -{{/panel}}
10134 -
10135 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
10136 -
10137 -----
10138 -
10139 -(% 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}}
10140 -
10141 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
10142 -
10143 -----
10144 -
10145 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
10146 -{"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}
10147 -{{/code}}
10148 -
10149 -==== Example ====
10150 -
10151 -----
10152 -
10153 -(% style="color: rgb(107,107,107);" %)Request
10154 -
10155 -{{code language="php" theme="RDark" title="Update Resource Request" collapse="true"}}
10156 - <?php
10157 -
10158 -$curl = curl_init();
10159 -
10160 -curl_setopt_array($curl, array(
10161 - CURLOPT_URL => 'https://api.onecount.net/v2/resources/{{resource id}}',
10162 - CURLOPT_RETURNTRANSFER => true,
10163 - CURLOPT_ENCODING => '',
10164 - CURLOPT_MAXREDIRS => 10,
10165 - CURLOPT_TIMEOUT => 0,
10166 - CURLOPT_FOLLOWLOCATION => true,
10167 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
10168 - CURLOPT_CUSTOMREQUEST => 'PUT',
10169 - 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}',
10170 - CURLOPT_HTTPHEADER => array(
10171 - 'Appkey: {{ONECOUNT API KEY}}'
10172 - ),
10173 -));
10174 -
10175 -$response = curl_exec($curl);
10176 -
10177 -curl_close($curl);
10178 -echo $response;
10179 -{{/code}}
10180 -
10181 10181  \\
10182 10182  
10183 -(% style="color: rgb(107,107,107);" %)Response  200 OK
10184 -
10185 -{{code language="yml" theme="RDark" title="Update Resource Response" collapse="true"}}
10186 - {
10187 - "result": {
10188 - "success": "1",
10189 - "error": {
10190 - "code": "",
10191 - "message": ""
10192 - }
10193 - },
10194 - "Resources": [
10195 - {
10196 - "Id": 903,
10197 - "Name": "Test API product creation 23",
10198 - "Description": "Test API product creation 23",
10199 - "Type": "3",
10200 - "Value": "http://one-count.com",
10201 - "FreePass": 1
10202 - },
10203 - {
10204 - "Id": 903,
10205 - "Name": "Test API product creation 23",
10206 - "Description": "Test API product creation 23",
10207 - "Type": "3",
10208 - "Value": "onecount.net",
10209 - "FreePass": 1
10210 - }
10211 - ]
10212 -}
10213 -{{/code}}
10214 -
10215 10215  (% class="western" %)
10216 10216  \\
10217 10217  
10218 10218  (% class="western" %)
10219 -=== **COMPONENT: Source Codes
10220 -** ===
9697 +**COMPONENT: Source Codes
9698 +**
10221 10221  
10222 10222  (% class="western" %)
10223 10223  This resource is for manipulating source code for a resource. A source code can be created, updated or searched.
... ... @@ -10320,7 +10320,7 @@
10320 10320  $curl = curl_init();
10321 10321  
10322 10322  curl_setopt_array($curl, array(
10323 - CURLOPT_URL => 'https://api.onecount.net/v2/sources',
9801 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/sources',
10324 10324   CURLOPT_RETURNTRANSFER => true,
10325 10325   CURLOPT_ENCODING => '',
10326 10326   CURLOPT_MAXREDIRS => 10,
... ... @@ -10536,7 +10536,7 @@
10536 10536  $curl = curl_init();
10537 10537  
10538 10538  curl_setopt_array($curl, array(
10539 - CURLOPT_URL => 'https://api.onecount.net/v2/sources/{{source code id}}',
10017 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/sources/{{source code id}}',
10540 10540   CURLOPT_RETURNTRANSFER => true,
10541 10541   CURLOPT_ENCODING => '',
10542 10542   CURLOPT_MAXREDIRS => 10,
... ... @@ -10587,7 +10587,7 @@
10587 10587  ----
10588 10588  
10589 10589  {{panel bgColor="#D3D3D3" width="100%"}}
10590 -(% 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
10591 10591  {{/panel}}
10592 10592  
10593 10593  === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
... ... @@ -10600,7 +10600,8 @@
10600 10600  
10601 10601  ----
10602 10602  
10603 -(% 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
10604 10604  
10605 10605  ==== Example ====
10606 10606  
... ... @@ -10608,222 +10608,27 @@
10608 10608  
10609 10609  (% style="color: rgb(107,107,107);" %)Request
10610 10610  
10611 -{{code language="php" theme="RDark" title="Lookup Source code Request" collapse="true"}}
10612 - <?php
10090 +{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}}
10613 10613  
10614 -$curl = curl_init();
10615 -
10616 -curl_setopt_array($curl, array(
10617 - CURLOPT_URL => 'https://api.onecount.net/v2/sources/lookup?Source={{Source code Name}}',
10618 - CURLOPT_RETURNTRANSFER => true,
10619 - CURLOPT_ENCODING => '',
10620 - CURLOPT_MAXREDIRS => 10,
10621 - CURLOPT_TIMEOUT => 0,
10622 - CURLOPT_FOLLOWLOCATION => true,
10623 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
10624 - CURLOPT_CUSTOMREQUEST => 'GET',
10625 - CURLOPT_HTTPHEADER => array(
10626 - 'Appkey: {{ONECOUNT API KEY}}'
10627 - ),
10628 -));
10629 -
10630 -$response = curl_exec($curl);
10631 -
10632 -curl_close($curl);
10633 -echo $response;
10634 -{{/code}}
10635 -
10636 10636  \\
10637 10637  
10638 10638  (% style="color: rgb(107,107,107);" %)Response  200 OK
10639 10639  
10640 -{{code language="yml" theme="RDark" title="Lookup Source code Response" collapse="true"}}
10641 - {
10642 - "result": {
10643 - "success": "1",
10644 - "error": {
10645 - "code": "",
10646 - "message": ""
10647 - }
10648 - },
10649 - "Sources": [
10650 - {
10651 - "Id": 26,
10652 - "Source": "GCN-Member",
10653 - "Description": "Uploaded from Reston VA",
10654 - "Parent": 0
10655 - }
10656 - ]
10657 -}
10658 -{{/code}}
10096 +{{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"/}}
10659 10659  
10660 10660  \\
10661 10661  
10662 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
10663 -== (% 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(%%) ==
10664 -
10665 -----
10666 -
10667 -{{panel bgColor="#D3D3D3" width="100%"}}
10668 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/sources
10669 -{{/panel}}
10670 -
10671 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
10672 -
10673 -----
10674 -
10675 -(% 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}}
10676 -
10677 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
10678 -
10679 -----
10680 -
10681 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
10682 -{"Source":"Test source code from API"}
10683 -{{/code}}
10684 -
10685 -==== Example ====
10686 -
10687 -----
10688 -
10689 -(% style="color: rgb(107,107,107);" %)Request
10690 -
10691 -{{code language="php" theme="RDark" title="Create Source code Request" collapse="true"}}
10692 - <?php
10693 -
10694 -$curl = curl_init();
10695 -
10696 -curl_setopt_array($curl, array(
10697 - CURLOPT_URL => 'https://api.onecount.net/v2/sources',
10698 - CURLOPT_RETURNTRANSFER => true,
10699 - CURLOPT_ENCODING => '',
10700 - CURLOPT_MAXREDIRS => 10,
10701 - CURLOPT_TIMEOUT => 0,
10702 - CURLOPT_FOLLOWLOCATION => true,
10703 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
10704 - CURLOPT_CUSTOMREQUEST => 'POST',
10705 - CURLOPT_POSTFIELDS =>'{"Source":"Test source code from API"}',
10706 - CURLOPT_HTTPHEADER => array(
10707 - 'Appkey: {{ONECOUNT API KEY}}'
10708 - ),
10709 -));
10710 -
10711 -$response = curl_exec($curl);
10712 -
10713 -curl_close($curl);
10714 -echo $response;
10715 -{{/code}}
10716 -
10717 10717  \\
10718 10718  
10719 -(% style="color: rgb(107,107,107);" %)Response  200 OK
10720 -
10721 -{{code language="yml" theme="RDark" title="Create Source code Response" collapse="true"}}
10722 - {
10723 - "result": {
10724 - "success": "1",
10725 - "error": {
10726 - "code": "",
10727 - "message": ""
10728 - }
10729 - },
10730 - "Sources": [
10731 - {
10732 - "Id": 223,
10733 - "Source": "Test source code from API",
10734 - "Description": "",
10735 - "Parent": 0
10736 - }
10737 - ]
10738 -}
10739 -{{/code}}
10740 -
10741 10741  \\
10742 10742  
10743 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
10744 -== (% 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(%%) ==
10745 -
10746 -----
10747 -
10748 -{{panel bgColor="#D3D3D3" width="100%"}}
10749 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/sources/~{~{source code id}}
10750 -{{/panel}}
10751 -
10752 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
10753 -
10754 -----
10755 -
10756 -(% 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}}
10757 -
10758 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
10759 -
10760 -----
10761 -
10762 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
10763 -{"Source":"Test API","Parent":215}
10764 -{{/code}}
10765 -
10766 -==== Example ====
10767 -
10768 -----
10769 -
10770 -(% style="color: rgb(107,107,107);" %)Request
10771 -
10772 -{{code language="php" theme="RDark" title="Update Source code Request" collapse="true"}}
10773 - <?php
10774 -
10775 -$curl = curl_init();
10776 -
10777 -curl_setopt_array($curl, array(
10778 - CURLOPT_URL => 'https://api.onecount.net/v2/sources/{{source code id}}',
10779 - CURLOPT_RETURNTRANSFER => true,
10780 - CURLOPT_ENCODING => '',
10781 - CURLOPT_MAXREDIRS => 10,
10782 - CURLOPT_TIMEOUT => 0,
10783 - CURLOPT_FOLLOWLOCATION => true,
10784 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
10785 - CURLOPT_CUSTOMREQUEST => 'PUT',
10786 - CURLOPT_POSTFIELDS =>'{"Source":"Test API","Parent":215}',
10787 - CURLOPT_HTTPHEADER => array(
10788 - 'Appkey: {{ONECOUNT API KEY}}'
10789 - ),
10790 -));
10791 -
10792 -$response = curl_exec($curl);
10793 -
10794 -curl_close($curl);
10795 -echo $response;
10796 -{{/code}}
10797 -
10798 10798  \\
10799 10799  
10800 -(% style="color: rgb(107,107,107);" %)Response  200 OK
10801 -
10802 -{{code language="yml" theme="RDark" title="Update Source code Response" collapse="true"}}
10803 - {
10804 - "result": {
10805 - "success": "1",
10806 - "error": {
10807 - "code": "",
10808 - "message": ""
10809 - }
10810 - },
10811 - "Sources": [
10812 - {
10813 - "Id": 223,
10814 - "Source": "Test API",
10815 - "Description": "",
10816 - "Parent": 215
10817 - }
10818 - ]
10819 -}
10820 -{{/code}}
10821 -
10822 10822  (% class="western" %)
10823 10823  \\
10824 10824  
10825 10825  (% class="western" %)
10826 -=== **COMPONENT: Transactions** ===
10110 +**COMPONENT: Transactions**
10827 10827  
10828 10828  (% class="western" %)
10829 10829  This resource is for manipulating transactions resource. A transaction can be created or searched.
... ... @@ -10913,7 +10913,7 @@
10913 10913  $curl = curl_init();
10914 10914  
10915 10915  curl_setopt_array($curl, array(
10916 - CURLOPT_URL => 'https://api.onecount.net/v2/transactions',
10200 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/transactions?limit=100',
10917 10917   CURLOPT_RETURNTRANSFER => true,
10918 10918   CURLOPT_ENCODING => '',
10919 10919   CURLOPT_MAXREDIRS => 10,
... ... @@ -12479,7 +12479,7 @@
12479 12479  $curl = curl_init();
12480 12480  
12481 12481  curl_setopt_array($curl, array(
12482 - CURLOPT_URL => 'https://api.onecount.net/v2/transactions/{{Transaction id}}',
11766 + CURLOPT_URL => 'rayaan.onecount.net/api/v2/transactions/{{Transaction id}}',
12483 12483   CURLOPT_RETURNTRANSFER => true,
12484 12484   CURLOPT_ENCODING => '',
12485 12485   CURLOPT_MAXREDIRS => 10,
... ... @@ -12539,7 +12539,7 @@
12539 12539  ----
12540 12540  
12541 12541  {{panel bgColor="#D3D3D3" width="100%"}}
12542 -(% 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
12543 12543  {{/panel}}
12544 12544  
12545 12545  === (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
... ... @@ -12552,7 +12552,8 @@
12552 12552  
12553 12553  ----
12554 12554  
12555 -(% 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
12556 12556  
12557 12557  ==== Example ====
12558 12558  
... ... @@ -12560,720 +12560,65 @@
12560 12560  
12561 12561  (% style="color: rgb(107,107,107);" %)Request
12562 12562  
12563 -{{code language="php" theme="RDark" title="Lookup Transaction Request" collapse="true"}}
12564 - <?php
11848 +{{code language="php" theme="RDark" title="Lookup user Request" collapse="true"/}}
12565 12565  
12566 -$curl = curl_init();
12567 -
12568 -curl_setopt_array($curl, array(
12569 - CURLOPT_URL => 'https://api.onecount.net/v2/transactions/lookup?UserId={{OCID}}',
12570 - CURLOPT_RETURNTRANSFER => true,
12571 - CURLOPT_ENCODING => '',
12572 - CURLOPT_MAXREDIRS => 10,
12573 - CURLOPT_TIMEOUT => 0,
12574 - CURLOPT_FOLLOWLOCATION => true,
12575 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
12576 - CURLOPT_CUSTOMREQUEST => 'GET',
12577 - CURLOPT_HTTPHEADER => array(
12578 - 'Appkey: {{ONECOUNT API KEY}}'
12579 - ),
12580 -));
12581 -
12582 -$response = curl_exec($curl);
12583 -
12584 -curl_close($curl);
12585 -echo $response;
12586 -{{/code}}
12587 -
12588 12588  \\
12589 12589  
12590 12590  (% style="color: rgb(107,107,107);" %)Response  200 OK
12591 12591  
12592 -{{code language="yml" theme="RDark" title="Lookup Transaction Response" collapse="true"}}
12593 - {
12594 - "result": {
12595 - "success": "1",
12596 - "error": {
12597 - "code": "",
12598 - "message": ""
12599 - }
12600 - },
12601 - "Transactions": [
12602 - {
12603 - "Id": 52494786,
12604 - "UserId": 1234,
12605 - "TermId": 34,
12606 - "TransactionDate": "2016-01-19",
12607 - "TransactionTime": "15:30:04",
12608 - "RequestDate": "2016-01-19",
12609 - "UserIP": "12.226.247.2",
12610 - "SubscriptionType": "u",
12611 - "ProductId": 34,
12612 - "Source": 0,
12613 - "ProductStatus": 0,
12614 - "MediaFilePath": "",
12615 - "Amount": ""
12616 - },
12617 - {
12618 - "Id": 42654041,
12619 - "UserId": 1234,
12620 - "TermId": 34,
12621 - "TransactionDate": "2015-09-09",
12622 - "TransactionTime": "11:20:39",
12623 - "RequestDate": "2015-09-09",
12624 - "UserIP": "24.187.236.98",
12625 - "SubscriptionType": "n",
12626 - "ProductId": 34,
12627 - "Source": 0,
12628 - "ProductStatus": 2,
12629 - "MediaFilePath": "",
12630 - "Amount": ""
12631 - },
12632 - {
12633 - "Id": 97251022,
12634 - "UserId": 1234,
12635 - "TermId": 34,
12636 - "TransactionDate": "2015-06-04",
12637 - "TransactionTime": "14:59:42",
12638 - "RequestDate": "2015-06-04",
12639 - "UserIP": "12.226.247.2",
12640 - "SubscriptionType": "u",
12641 - "ProductId": 34,
12642 - "Source": 0,
12643 - "ProductStatus": 0,
12644 - "MediaFilePath": "",
12645 - "Amount": ""
12646 - },
12647 - {
12648 - "Id": 55492559,
12649 - "UserId": 1234,
12650 - "TermId": 34,
12651 - "TransactionDate": "2015-04-03",
12652 - "TransactionTime": "16:32:04",
12653 - "RequestDate": "2015-04-03",
12654 - "UserIP": "24.187.236.98",
12655 - "SubscriptionType": "r",
12656 - "ProductId": 34,
12657 - "Source": 58,
12658 - "ProductStatus": 106,
12659 - "MediaFilePath": "",
12660 - "Amount": ""
12661 - },
12662 - {
12663 - "Id": 98173391,
12664 - "UserId": 1234,
12665 - "TermId": 34,
12666 - "TransactionDate": "2015-04-03",
12667 - "TransactionTime": "15:50:45",
12668 - "RequestDate": "2014-08-19",
12669 - "UserIP": "24.187.236.98",
12670 - "SubscriptionType": "n",
12671 - "ProductId": 34,
12672 - "Source": 34,
12673 - "ProductStatus": 106,
12674 - "MediaFilePath": "",
12675 - "Amount": ""
12676 - },
12677 - {
12678 - "Id": 91711793,
12679 - "UserId": 1234,
12680 - "TermId": 18,
12681 - "TransactionDate": "2015-04-27",
12682 - "TransactionTime": "14:24:51",
12683 - "RequestDate": "2015-04-27",
12684 - "UserIP": "24.187.236.98",
12685 - "SubscriptionType": "u",
12686 - "ProductId": 18,
12687 - "Source": 0,
12688 - "ProductStatus": 106,
12689 - "MediaFilePath": "",
12690 - "Amount": ""
12691 - },
12692 - {
12693 - "Id": 74936400,
12694 - "UserId": 1234,
12695 - "TermId": 18,
12696 - "TransactionDate": "2015-04-27",
12697 - "TransactionTime": "12:35:18",
12698 - "RequestDate": "2015-04-27",
12699 - "UserIP": "68.196.187.74",
12700 - "SubscriptionType": "n",
12701 - "ProductId": 18,
12702 - "Source": 34,
12703 - "ProductStatus": 106,
12704 - "MediaFilePath": "",
12705 - "Amount": ""
12706 - },
12707 - {
12708 - "Id": 21664714,
12709 - "UserId": 1234,
12710 - "TermId": 18,
12711 - "TransactionDate": "2015-04-03",
12712 - "TransactionTime": "15:50:46",
12713 - "RequestDate": "2015-04-03",
12714 - "UserIP": "24.187.236.98",
12715 - "SubscriptionType": "u",
12716 - "ProductId": 18,
12717 - "Source": 0,
12718 - "ProductStatus": 2,
12719 - "MediaFilePath": "",
12720 - "Amount": ""
12721 - },
12722 - {
12723 - "Id": 81129263,
12724 - "UserId": 1234,
12725 - "TermId": 18,
12726 - "TransactionDate": "2014-08-19",
12727 - "TransactionTime": "11:18:55",
12728 - "RequestDate": "2014-08-19",
12729 - "UserIP": "74.201.38.1",
12730 - "SubscriptionType": "n",
12731 - "ProductId": 18,
12732 - "Source": 34,
12733 - "ProductStatus": 2,
12734 - "MediaFilePath": "",
12735 - "Amount": ""
12736 - },
12737 - {
12738 - "Id": 30461748,
12739 - "UserId": 1234,
12740 - "ResourceId": 459,
12741 - "TransactionDate": "2023-03-15",
12742 - "TransactionTime": "12:07:55",
12743 - "RequestDate": "2023-03-15",
12744 - "UserIP": "74.201.38.12",
12745 - "SubscriptionType": "n",
12746 - "SourceCode": 0,
12747 - "ProductStatus": 0,
12748 - "MediaFilePath": "",
12749 - "Amount": ""
12750 - },
12751 - {
12752 - "Id": 25858253,
12753 - "UserId": 1234,
12754 - "ResourceId": 451,
12755 - "TransactionDate": "2023-03-15",
12756 - "TransactionTime": "11:45:19",
12757 - "RequestDate": "2023-03-15",
12758 - "UserIP": "74.201.38.12",
12759 - "SubscriptionType": "n",
12760 - "SourceCode": 0,
12761 - "ProductStatus": 0,
12762 - "MediaFilePath": "",
12763 - "Amount": ""
12764 - },
12765 - {
12766 - "Id": 69453260,
12767 - "UserId": 1234,
12768 - "ResourceId": 411,
12769 - "TransactionDate": "2022-06-07",
12770 - "TransactionTime": "17:03:14",
12771 - "RequestDate": "2022-06-07",
12772 - "UserIP": "74.201.38.12",
12773 - "SubscriptionType": "n",
12774 - "SourceCode": 0,
12775 - "ProductStatus": 0,
12776 - "MediaFilePath": "",
12777 - "Amount": ""
12778 - },
12779 - {
12780 - "Id": 51354425,
12781 - "UserId": 1234,
12782 - "ResourceId": 355,
12783 - "TransactionDate": "2020-04-06",
12784 - "TransactionTime": "12:24:08",
12785 - "RequestDate": "2020-04-06",
12786 - "UserIP": "74.201.38.12",
12787 - "SubscriptionType": "n",
12788 - "SourceCode": 0,
12789 - "ProductStatus": 0,
12790 - "MediaFilePath": "",
12791 - "Amount": ""
12792 - }
12793 - ]
12794 -}
12795 -{{/code}}
11854 +{{code language="yml" theme="RDark" title="Lookup user Response" collapse="true"/}}
12796 12796  
12797 12797  \\
12798 12798  
12799 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
12800 -== (% 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(%%) ==
11858 +\\
12801 12801  
12802 -----
11860 +\\
12803 12803  
12804 -{{panel bgColor="#D3D3D3" width="100%"}}
12805 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/transactions
12806 -{{/panel}}
11862 +\\
12807 12807  
12808 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
11864 +\\
12809 12809  
12810 -----
11866 +\\
12811 12811  
12812 -(% 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}}
11868 +\\
12813 12813  
12814 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
11870 +\\
12815 12815  
12816 -----
11872 +\\
12817 12817  
12818 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
12819 -{"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" }
12820 -{{/code}}
11874 +\\
12821 12821  
12822 -==== Example ====
11876 +\\
12823 12823  
12824 -----
11878 +\\
12825 12825  
12826 -(% style="color: rgb(107,107,107);" %)Request
11880 +\\
12827 12827  
12828 -{{code language="php" theme="RDark" title="Create Transaction Request" collapse="true"}}
12829 - <?php
11882 +\\
12830 12830  
12831 -$curl = curl_init();
11884 +\\
12832 12832  
12833 -curl_setopt_array($curl, array(
12834 - CURLOPT_URL => 'https://api.onecount.net/v2/transactions',
12835 - CURLOPT_RETURNTRANSFER => true,
12836 - CURLOPT_ENCODING => '',
12837 - CURLOPT_MAXREDIRS => 10,
12838 - CURLOPT_TIMEOUT => 0,
12839 - CURLOPT_FOLLOWLOCATION => true,
12840 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
12841 - CURLOPT_CUSTOMREQUEST => 'POST',
12842 - 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" }',
12843 - CURLOPT_HTTPHEADER => array(
12844 - 'Appkey: {{ONECOUNT API KEY}}'
12845 - ),
12846 -));
11886 +\\
12847 12847  
12848 -$response = curl_exec($curl);
12849 -
12850 -curl_close($curl);
12851 -echo $response;
12852 -{{/code}}
12853 -
12854 12854  \\
12855 12855  
12856 -(% style="color: rgb(107,107,107);" %)Response  200 OK
12857 -
12858 -{{code language="yml" theme="RDark" title="Create Transaction Response" collapse="true"}}
12859 - {
12860 - "result": {
12861 - "success": "1",
12862 - "error": {
12863 - "code": "",
12864 - "message": ""
12865 - }
12866 - },
12867 - "Transactions": {
12868 - "Id": "1234",
12869 - "UserId": 1845775,
12870 - "TermId": 447,
12871 - "TransactionDate": "20231211",
12872 - "TransactionTime": "09:34:26",
12873 - "RequestDate": "20231211",
12874 - "UserIP": "192.168.0.1",
12875 - "SubscriptionType": "n",
12876 - "ProductId": 599,
12877 - "Source": 83,
12878 - "ProductStatus": 2,
12879 - "MediaFilePath": "",
12880 - "Amount": "0.00"
12881 - }
12882 -}
12883 -{{/code}}
12884 -
12885 12885  \\
12886 12886  
12887 -=== **COMPONENT: Engagements** ===
12888 -
12889 -(% class="western" %)
12890 -Engagement can be added, updated and searched for using the engagements resource from the api.
12891 -
12892 -(% class="western" %)
12893 12893  \\
12894 12894  
12895 -(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12896 -(((
12897 -(% class="western" %)
12898 -**Method**
12899 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12900 -(((
12901 -(% class="western" %)
12902 -**Url**
12903 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12904 -(((
12905 -(% class="western" %)
12906 -**Action**
12907 -)))
12908 -(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12909 -(((
12910 -(% class="western" %)
12911 -GET
12912 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12913 -(((
12914 -(% class="western" %)
12915 -/(% style="color: rgb(33,33,33);" %)engagements
12916 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12917 -(((
12918 -(% class="western" %)
12919 -Get engagement data limiting 25.
12920 -)))
12921 -(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12922 -(((
12923 -(% class="western" %)
12924 -GET
12925 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12926 -(((
12927 -(% class="western" %)
12928 -/(% style="color: rgb(33,33,33);" %)engagements(%%)/<engagement id>
12929 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12930 -(((
12931 -(% class="western" %)
12932 -Get data for engagement id. The engagement id is a string
12933 -)))
12934 -(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12935 -(((
12936 -(% class="western" %)
12937 -POST
12938 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12939 -(((
12940 -(% class="western" %)
12941 -/(% style="color: rgb(33,33,33);" %)engagements
12942 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12943 -(((
12944 -(% class="western" %)
12945 -Create a new engagement
12946 -
12947 -(% class="western" %)
12948 -Parameters required to create the engagement needs to be sent as post data in JSON format.
12949 -)))
12950 -(% class="" %)|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12951 -(((
12952 -(% class="western" %)
12953 -PUT
12954 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12955 -(((
12956 -(% class="western" %)
12957 -/(% style="color: rgb(33,33,33);" %)engagements(%%)/<engagement id>
12958 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12959 -(((
12960 -(% class="western" %)
12961 -Update engagement by engagement id. The engagement id string
12962 -
12963 -(% class="western" %)
12964 -Parameters required to update the engagement needs to be sent as post data in JSON format.
12965 -)))
12966 -|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12967 -(((
12968 -(% class="western" %)
12969 -POST
12970 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12971 -(((
12972 -(% class="western" %)
12973 -(% style="color: rgb(33,33,33);" %)/engagements/addUser
12974 -)))|(% style="text-align: left;vertical-align: top;" %)(% style="text-align: left;vertical-align: top;" %)
12975 -(((
12976 -(% class="western" %)
12977 -Add user to engagement
12978 -
12979 -(% class="western" %)
12980 -Parameters required to add user to the engagement needs to be sent as post data in JSON format.
12981 -)))
12982 -
12983 12983  \\
12984 12984  
12985 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
12986 -== (% 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(%%) ==
12987 -
12988 -----
12989 -
12990 -----
12991 -
12992 -{{panel bgColor="#D3D3D3" width="100%"}}
12993 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements
12994 -{{/panel}}
12995 -
12996 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
12997 -
12998 -----
12999 -
13000 -(% 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}}
13001 -
13002 -==== Example ====
13003 -
13004 -----
13005 -
13006 -(% style="color: rgb(107,107,107);" %)Request
13007 -
13008 -{{code language="php" theme="RDark" title="Get All Engagement Request" collapse="true"}}
13009 -<?php
13010 -
13011 -$curl = curl_init();
13012 -
13013 -curl_setopt_array($curl, array(
13014 - CURLOPT_URL => 'https://api.onecount.net/v2/engagements',
13015 - CURLOPT_RETURNTRANSFER => true,
13016 - CURLOPT_ENCODING => '',
13017 - CURLOPT_MAXREDIRS => 10,
13018 - CURLOPT_TIMEOUT => 0,
13019 - CURLOPT_FOLLOWLOCATION => true,
13020 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13021 - CURLOPT_CUSTOMREQUEST => 'GET',
13022 - CURLOPT_HTTPHEADER => array(
13023 - 'Appkey: {{ONECOUNT API KEY}}'
13024 - ),
13025 -));
13026 -
13027 -$response = curl_exec($curl);
13028 -
13029 -curl_close($curl);
13030 -echo $response;
13031 -
13032 -
13033 -{{/code}}
13034 -
13035 13035  \\
13036 13036  
13037 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
13038 -== (% 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(%%) ==
13039 -
13040 -----
13041 -
13042 -----
13043 -
13044 -{{panel bgColor="#D3D3D3" width="100%"}}
13045 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements/~{~{Engagement ID}}
13046 -{{/panel}}
13047 -
13048 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
13049 -
13050 -----
13051 -
13052 -(% 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}}
13053 -
13054 -==== Example ====
13055 -
13056 -----
13057 -
13058 -(% style="color: rgb(107,107,107);" %)Request
13059 -
13060 -{{code language="php" theme="RDark" title="Get Specific Engagement Request" collapse="true"}}
13061 -<?php
13062 -
13063 -$curl = curl_init();
13064 -
13065 -curl_setopt_array($curl, array(
13066 - CURLOPT_URL => 'https://api.onecount.net/v2/engagements/{{Engagement ID}}',
13067 - CURLOPT_RETURNTRANSFER => true,
13068 - CURLOPT_ENCODING => '',
13069 - CURLOPT_MAXREDIRS => 10,
13070 - CURLOPT_TIMEOUT => 0,
13071 - CURLOPT_FOLLOWLOCATION => true,
13072 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13073 - CURLOPT_CUSTOMREQUEST => 'GET',
13074 - CURLOPT_HTTPHEADER => array(
13075 - 'Appkey: {{ONECOUNT API KEY}}'
13076 - ),
13077 -));
13078 -
13079 -$response = curl_exec($curl);
13080 -
13081 -curl_close($curl);
13082 -echo $response;
13083 -
13084 -
13085 -{{/code}}
13086 -
13087 13087  \\
13088 13088  
13089 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
13090 -== (% 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(%%) ==
13091 -
13092 -----
13093 -
13094 -{{panel bgColor="#D3D3D3" width="100%"}}
13095 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements
13096 -{{/panel}}
13097 -
13098 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
13099 -
13100 -----
13101 -
13102 -(% 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}}
13103 -
13104 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
13105 -
13106 -----
13107 -
13108 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
13109 -{"Name":"Engagement Name", "Description":"Engagement Description", "Metrics":[
13110 - {"Name":[{"webinar ID 1":"Webinar 1"},{"webinar ID 3":"Webinar 3"},{"webinar ID 3":"Webinar 3"}],"Type": "select"},
13111 - {"Attendance Status":[{"attended":"Attended"},{"not_attended":"Not Attended"}],"Type": "select"},
13112 - {"Price":[],"Type": "numeric"},
13113 - {"Transaction Date":[],"Type": "date"}
13114 -]}
13115 -{{/code}}
13116 -
13117 -==== Example ====
13118 -
13119 -----
13120 -
13121 -(% style="color: rgb(107,107,107);" %)Request
13122 -
13123 -{{code language="php" theme="RDark" title="Create Engagement Request" collapse="true"}}
13124 - <?php
13125 -
13126 -$curl = curl_init();
13127 -
13128 -curl_setopt_array($curl, array(
13129 - CURLOPT_URL => 'https://api.onecount.net/v2/engagements',
13130 - CURLOPT_RETURNTRANSFER => true,
13131 - CURLOPT_ENCODING => '',
13132 - CURLOPT_MAXREDIRS => 10,
13133 - CURLOPT_TIMEOUT => 0,
13134 - CURLOPT_FOLLOWLOCATION => true,
13135 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13136 - CURLOPT_CUSTOMREQUEST => 'POST',
13137 - CURLOPT_POSTFIELDS =>'{"Name":"Engagement Name", "Description":"Engagement Description", "Metrics":[
13138 - {"Name":[{"webinar ID 1":"Webinar 1"},{"webinar ID 3":"Webinar 3"},{"webinar ID 3":"Webinar 3"}],"Type": "select"},
13139 - {"Attendance Status":[{"attended":"Attended"},{"not_attended":"Not Attended"}],"Type": "select"},
13140 - {"Price":[],"Type": "numeric"},
13141 - {"Transaction Date":[],"Type": "date"}
13142 -]}',
13143 - CURLOPT_HTTPHEADER => array(
13144 - 'Appkey: {{ONECOUNT API KEY}}'
13145 - ),
13146 -));
13147 -
13148 -$response = curl_exec($curl);
13149 -
13150 -curl_close($curl);
13151 -echo $response;
13152 -{{/code}}
13153 -
13154 13154  \\
13155 13155  
13156 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
13157 -== (% 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(%%) ==
13158 -
13159 -----
13160 -
13161 -{{panel bgColor="#D3D3D3" width="100%"}}
13162 - (% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements/~{~{Engagement Id}}
13163 -{{/panel}}
13164 -
13165 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
13166 -
13167 -----
13168 -
13169 -(% 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}}
13170 -
13171 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
13172 -
13173 -----
13174 -
13175 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
13176 -{"Name":"Engagement Name", "Description":"Engagement Description", "Metrics":[
13177 - {"Name":[{"webinar ID 5":"Webinar 5"},{"webinar ID 4":"Webinar 4"}],"Type": "select"},
13178 - {"Price":[],"Type": "text"}
13179 -]}
13180 -{{/code}}
13181 -
13182 -==== Example ====
13183 -
13184 -----
13185 -
13186 -(% style="color: rgb(107,107,107);" %)Request
13187 -
13188 -{{code language="php" theme="RDark" title="Update Engagement Request" collapse="true"}}
13189 - <?php
13190 -
13191 -$curl = curl_init();
13192 -
13193 -curl_setopt_array($curl, array(
13194 - CURLOPT_URL => 'https://api.onecount.net/v2/engagements/{{Engagement Id}}',
13195 - CURLOPT_RETURNTRANSFER => true,
13196 - CURLOPT_ENCODING => '',
13197 - CURLOPT_MAXREDIRS => 10,
13198 - CURLOPT_TIMEOUT => 0,
13199 - CURLOPT_FOLLOWLOCATION => true,
13200 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13201 - CURLOPT_CUSTOMREQUEST => 'PUT',
13202 - CURLOPT_POSTFIELDS =>'{"Name":"Engagement Name", "Description":"Engagement Description", "Metrics":[
13203 - {"Name":[{"webinar ID 5":"Webinar 5"},{"webinar ID 4":"Webinar 4"}],"Type": "select"},
13204 - {"Price":[],"Type": "text"}
13205 -]}',
13206 - CURLOPT_HTTPHEADER => array(
13207 - 'Appkey: {{ONECOUNT API KEY}}'
13208 - ),
13209 -));
13210 -
13211 -$response = curl_exec($curl);
13212 -
13213 -curl_close($curl);
13214 -echo $response;
13215 -{{/code}}
13216 -
13217 13217  \\
13218 13218  
13219 -(% style="margin-left: 0.0px;" class="sc-fznLPX cxTVKx" %)
13220 -== (% 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(%%) ==
13221 -
13222 -----
13223 -
13224 -{{panel bgColor="#D3D3D3" width="100%"}}
13225 -(% class="nolink" %)https:~/~/api.onecount.net/v2(% style="color: rgb(33,33,33);" %)/engagements/addUser
13226 -{{/panel}}
13227 -
13228 -=== (% class="core-title" style="color: rgb(33,33,33);" %)Request Headers(%%) ===
13229 -
13230 -----
13231 -
13232 -(% 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}}
13233 -
13234 -=== (% style="color: rgb(33,33,33);" %)Body (% style="color: rgb(107,107,107);" %)raw (json)(%%) ===
13235 -
13236 -----
13237 -
13238 -{{code language="yml" theme="RDark" title="Body" collapse="true"}}
13239 -{"Engagement id":"073b3a98-129b-440e-90b1-57957215ca67","Vendor id":1, "Engagement show id":"webinar ID 4","User id":"3143231","timestamp":1702319997, "data":{"Attendance Status":"not_attended","Price":10.00},"segment":["segment id 1"]}
13240 -{{/code}}
13241 -
13242 -==== Example ====
13243 -
13244 -----
13245 -
13246 -(% style="color: rgb(107,107,107);" %)Request
13247 -
13248 -{{code language="php" theme="RDark" title="Add User to Engagement Request" collapse="true"}}
13249 - <?php
13250 -
13251 -$curl = curl_init();
13252 -
13253 -curl_setopt_array($curl, array(
13254 - CURLOPT_URL => 'https://api.onecount.net/v2/engagements/addUser',
13255 - CURLOPT_RETURNTRANSFER => true,
13256 - CURLOPT_ENCODING => '',
13257 - CURLOPT_MAXREDIRS => 10,
13258 - CURLOPT_TIMEOUT => 0,
13259 - CURLOPT_FOLLOWLOCATION => true,
13260 - CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13261 - CURLOPT_CUSTOMREQUEST => 'POST',
13262 - CURLOPT_POSTFIELDS =>'{"Engagement id":"073b3a98-129b-440e-90b1-57957215ca67","Vendor id":1, "Engagement show id":"webinar ID 4","User id":"3143231","timestamp":1702319997, "data":{"Attendance Status":"not_attended","Price":10.00},"segment":["segment id 1"]}',
13263 - CURLOPT_HTTPHEADER => array(
13264 - 'Appkey: {{ONECOUNT API KEY}}'
13265 - ),
13266 -));
13267 -
13268 -$response = curl_exec($curl);
13269 -
13270 -curl_close($curl);
13271 -echo $response;
13272 -{{/code}}
13273 -
13274 13274  (% class="western" %)
13275 -=== **COMPONENT: Leads
13276 -** ===
11905 +**COMPONENT: Leads
11906 +**
13277 13277  
13278 13278  (% class="western" %)
13279 13279  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.
... ... @@ -13458,6 +13458,14 @@
13458 13458  
13459 13459  \\
13460 13460  
12091 +\\
12092 +
12093 +\\
12094 +
12095 +\\
12096 +
12097 +\\
12098 +
13461 13461  (% class="western" %)
13462 13462  **API REFERENCE**
13463 13463  
Confluence.Code.ConfluencePageClass[0]
id
... ... @@ -1,1 +1,1 @@
1 -108265485
1 +108265481
url
... ... @@ -1,1 +1,1 @@
1 -https://info.onecount.net//wiki/spaces/OD/pages/108265485/ONEcount API Documentation
1 +https://info.onecount.net//wiki/spaces/OD/pages/108265481/ONEcount API Documentation