Difference between revisions of "MOR API Card Groups get"

From Kolmisoft Wiki
Jump to navigationJump to search
(Created page with '= NOTE: Available from MOR X7 = =Description= MOR API Calling Cards Groups get <br><br> =Usage= * From '''MOR X7''' Calling Cards Groups: '''/api/cc_groups_get''' * Methods…')
 
Line 11: Line 11:
===Parametres===
===Parametres===


* u - username for authentication. '''Required'''.
* u - username for authentication.
* cc_group_id - Calling Cards Group ID.
* cc_group_id - Calling Cards Group ID.
* [[MOR API hash construction | hash]] - SHA1 hash constructed using '''API_Secret_Key''' ([[MOR API hash construction | More described in Constructing hash]]). '''Required'''.
* [[MOR API hash construction | hash]] - SHA1 hash constructed using '''API_Secret_Key''' ([[MOR API hash construction | More described in Constructing hash]]). '''Required'''.

Revision as of 09:15, 5 November 2015

NOTE: Available from MOR X7

Description

MOR API Calling Cards Groups get

Usage

  • From MOR X7 Calling Cards Groups: /api/cc_groups_get
  • Methods: POST, GET(if allowed, not recomended)



Parametres



Request

We have: API Secret Key = secret

We send:

HTML POST: http://<SERVER_IP>/billing/api/cc_groups_get?u=admin&cc_group_id=1&hash=e5e9fa1ba31ecd1ae84f75caaa474f3a663f05f4

NOTE that username is not included in hash

Success

<page>
 <status>
  <group_id>1</group_id>
  <group_image>example.jpg</group_image>
  <group_name>Test_cardgroup</group_name>
  <group_description>Test_cardgroup description</group_description>
  <group_number_pin_length>10/4</group_number_pin_length>
  <group_tarrif>Test Tariff for Users</group_tarrif>
  <group_lcr>Primary</group_lcr>
  <group_price>10.0840</group_price>
  <group_price_without_tax>10.0840</group_price_without_tax>
  <group_cards_count>21</group_cards_count>
 </status>
</page>




Errors

  • <error>Bad login</error> - User supplied bad login.
  • <error>Incorrect hash</error> - Hash was not correct. Check API_Secret_Key and order or params while concatenating hash_string.
  • <error>You are not authorized to use this functionality</error> - User does not have rights to manage Calling Cards.
  • <error>Access Denied</error> - User does not have access to Calling Cards.
  • <error>Wrong calling cards group ID</error> - User supplied wrong Calling Cards group ID.
  • <error>Calling cards groups were not found</error> - Calling cards groups were not found.



See also