Difference between revisions of "MOR API rate get"
From Kolmisoft Wiki
Jump to navigationJump to search
(→Result) |
|||
Line 1: | Line 1: | ||
<!---This functionality is available from MOR 10, but was also backported to MOR 9 ---> | <!---This functionality is available from MOR 10, but was also backported to MOR 9 ---> | ||
=About= | =About= | ||
This feature enables you to check rate over http. | This feature enables you to check rate over http. | ||
<br><br> | |||
==Enable check check rate over http feature== | ==Enable check check rate over http feature== | ||
Line 18: | Line 17: | ||
[[File:Mor_api_rate_api_cfg.png]] | [[File:Mor_api_rate_api_cfg.png]] | ||
<br><br> | <br><br> | ||
==Request== | ==Request== | ||
HTML POST: http://<SERVER_IP>/billing/api/rate?username=USERNAME&prefix=PREFIX | HTML POST: http://<SERVER_IP>/billing/api/rate?username=USERNAME&prefix=PREFIX | ||
Example: http://127.0.0.1/billing/api/rate?username=admin&prefix=370 | Example: http://127.0.0.1/billing/api/rate?username=admin&prefix=370 | ||
<br><br> | |||
==Result== | ==Result== | ||
Line 30: | Line 28: | ||
'''NOTE.''' MOR API rate method shows rate, which is applied to User. If rate by prefix is not found in [[Custom Rates]], it will be taken from Tariff assigned to User. | '''NOTE.''' MOR API rate method shows rate, which is applied to User. If rate by prefix is not found in [[Custom Rates]], it will be taken from Tariff assigned to User. | ||
<br><br> | |||
==Problems and solutions== | |||
'''<status>GET Requests are disabled</status>''' <!--Rate was not found - useris neturi rates tam prefixui --> | |||
*You did not enabled GET API - enable it as described in step 3 | *You did not enabled GET API - enable it as described in step 3 | ||
<br><br> | <br><br> | ||
=See Also= | |||
* [[MOR API]] | * [[MOR API]] |
Revision as of 12:11, 7 March 2013
About
This feature enables you to check rate over http.
Enable check check rate over http feature
1. Go to SETTINGS - Setup -> Settings
2. In Various tab check the marked option:
3. Ensure that MOR API is enabled
Request
HTML POST: http://<SERVER_IP>/billing/api/rate?username=USERNAME&prefix=PREFIX Example: http://127.0.0.1/billing/api/rate?username=admin&prefix=370
Result
Result is returned in format: rate#destination#prefix Example: 35.0#Lithuania#370
NOTE. MOR API rate method shows rate, which is applied to User. If rate by prefix is not found in Custom Rates, it will be taken from Tariff assigned to User.
Problems and solutions
<status>GET Requests are disabled</status>
- You did not enabled GET API - enable it as described in step 3