GET wallets/get_product_available_amount

This method is used to get the amount which is available for specific products for a specific period of time and  a specific unit or group

Resource URL

Parameters

Name

Type

Description

token

String

The token retrieved from the login method

wallet_identifier

(mandatory)

Wallet identifier

The identifier of the wallet that should be returned as a result. The allowed wallets identifier fields are the following:

Name

Type

Description

id

(semi-optional)

String

The ID of the wallet

number

(semi-optional)

String

The number of the wallet

product_identifier
(mandatory)

Product Identifier

The product for which the amount will be calculated for . The allowed product identifier fields are the following:

Name

Type

Description

id

(semi-optional)

String

The ID of the product

code

(semi-optional)

String

The code of the product

alternative_code

(semi-optional)

String

The alternative code of  the product

business_unit_identifier

(semi-optional)

Business Unit identifier

The business unit for which the amount will be calculated for. The allowed business unit identifier fields are the following:

Name

Type

Description

id

(semi-optional)

String

The ID of the business unit

name

(semi-optional)

String

The code of the business unit

code

(semi-optional)

String

The code of the business unit

Available from CRM.COM R18.0.0

unit_identifier

(semi-optional)

Unit identifier

The unit for which the amount will be calculated for. The allowed unit identifier fields are the following:

Name

Type

Description

id

(semi-optional)

String

The ID of the Unit

name

(semi-optional)

String

The name of the Unit

alternative_code

(semi-optional)

String

The alternative code of  the Unit

Deprecated from CRM.COM R18.0.0

group_identifier

(semi-optional)

Group identifier

The group for which the amount will be calculated for. The allowed group identifier fields are the following:

Name

Type

Description

id

(semi-optional)

String

The ID of the group

name

(semi-optional)

String

The code of the group

alternative_code

(semi-optional)

String

The alternative code of  the group

Deprecated from CRM.COM R18.0.0

as_of_date

(mandatory)

Date fieldThe date for which the amount will be calculated for.

fields_set

(optional)

List of Strings, comma separated 

A list of fields that should be included in the results. If not specified then all the available fields will be returned

Restrictions

  • It is mandatory to specify one of the semi-optional parameters. Only one of those parameters is allowed to be specified.

Response Data

 wallet_available_product_amount response data object

Name

Type

Description

amountNumberThe available amount in wallet currency
alternative_amountNumber

The available amount in wallet alternative currency

Available from CRM.COM R14.2.0


as_of_dateDateThe date during which the amount will be available
currencyCurrency Object

The remaining available amount's currency

Available from CRM.COM R10.0.0

alternative_currencyCurrency Object

The remaining available amount's alternative currency

Available from CRM.COM R14.2.0

productProduct ObjectThe related product
business_unitBusiness Unit Object

The related business unit

Available from CRM.COM R18.0.0

unitUnit Object

The related unit

Deprecated from CRM.COM R18.0.0 (replaced with business_unit)

groupGroup Object

The related group

Deprecated from CRM.COM R18.0.0 (replaced with owned_by_business_unit)


Referred Objects Response Data

 currency object response data

Name

Type

Description

id

String

The ID of the retrieved currency

code

String

The code of the retrieved currency

prefix_symbolStringThe prefix symbol for the specified currency

suffix_symbol

StringThe suffix symbol for the specified currency
life_cycle_stateString

The life cycle state for the specified currency, which can be EFFECTIVE or NOT EFFECTIVE

Available from CRM.COM R14.0.0

integer_part_nameStringThe integer part name for the specified currency
decimal_part_nameStringThe decimal part name for the specified currency

 product object response data
Name
Type
Description
IdStringThe ID of the product
codeStringThe code of product

alternative_code

String

The alternative code of product

description

String

The description of product

priority_levelInteger

The priority level of the product

Available from CRM.COM R12.3.0

global_rateGlobal Rate Object

The global rate of the retrieved product

Available from CRM.COM R15.0.0

product_typeProduct type objectThe type of the product

Referred Objects Response Data

 product_type object data response
NameType Description
IdStringThe ID of the retrieved product type
nameStringThe Name of the retrieved product type
alternative_codeStringThe Alternative Code of the retrieved product type
descriptionStringThe Description of the retrieved product type
classificationStringThe Classification of the retrieved product type which can be SERVICES or PHYSICALGOODS
service_typeStringThe Service Type of the retrieved product type which can be TERMED, USAGE, ONETIME or EXPENSE
physical_good_typeStringThe physical Good Type of the retrieved product type which can be TRACEABLE or NONTRACEABLE
composition_methodStringThe Composition Method of the retrieved product type which can be FLAT, FLEXIBLEBUNDLE or FIXEDBUNDLE
used_for_provisioningBooleanThe flag shows if the retrieved product type is used for provisioning
udr_typeUsage Detail Record TypeThe UDR type related with the product type. This is applicable only if the product type is classified as SERVICES and the service type is set to USAGE
meter_reading_typeMeter Reading Type

The Meter Reading type related with the product type. This is applicable only for traceable physical goods

Available from CRM.COM R14.0.0

Referred Objects Response Data

 usage_detail_record_type object data response
NameType Description
IdStringThe ID of the retrieved usage detail record type
nameStringThe Name of the retrieved usage detail record type
alternative_codeStringThe Alternative Code of the retrieved usage detail record type
descriptionStringThe Description of the retrieved usage detail record type
unit_of_measurementStringThe Unit of measurement of the retrieved usage detail record type

Referred Objects Response Data

 unit_of_measurement object response data

Name

Type

Description

idStringThe identifier of the Unit of measurement

name

String

The name of the Unit of measurement

description

String

The description of the Unit of measurement

alternative_codeStringThe alternative code of the Unit of measurement

 

 meter_reading_type object data response
NameType Description
IdStringThe ID of the retrieved meter reading type
nameStringThe Name of the retrieved meter reading type
alternative_codeStringThe Alternative Code of the retrieved meter reading type
classificationStringThe Classification of the retrieved meter reading type
descriptionStringThe Description of the retrieved meter reading type
unit_of_measurementStringThe Unit of measurement of the retrieved meter reading type

Referred Objects Response Data

 unit_of_measurement object response data

Name

Type

Description

idStringThe identifier of the Unit of measurement

name

String

The name of the Unit of measurement

description

String

The description of the Unit of measurement

alternative_codeStringThe alternative code of the Unit of measurement

 global rate object response data

Name

Type

Description

id

String

The ID of the retrieved rate

rate_model

String

The price plan rate model which can be one of the following:

  • QUANTITYBASED
  • QUANTITYANDPERIODBASED
  • BILLABLEPERIODBASED
  • DURATIONBASED
  • FLATFEEBASED
  • USAGEBASED

From CRM.COM R17.0.0, QUANTITYANDMATURITYBASED is renamed to QUANTITYANDPERIODBASED

global_base_amountNumber

The base price of the product in the Global Price Plan

base_rate_applied_perString

The value for 'Base Rate Applied per'

Available when the rate model is 'Quantity & Quantity Based' and it is a selection between

  • Period
  • Period_Item
uotString

The 'UOT' applicable for the rate

  • Seconds
  • Minute
  • Hour
  • Day
  • Week
  • Month
  • Year

Available for one-time services

time_periodTime Period Object

 The period and unit of time for which the base amount is applicable for. This is available only on termed services rates.

uomString

The 'UOM' applicable for the rate

Available when the product type is of Usage Service Classification 

Referred Objects Response Data

 period object response data

Name

Type

Description

time_period_valueNumber

The time period value

time_period_uot

String

The time period unit of time. The supported values are the following:

MINUTES, HOURS, DAYS, WEEKS, MONTHS, YEARS

 unit object response data

Name

Type

Description

id

String

The ID of the retrieved unit

name

String

The name of the retrieved unit

group_name

String

The name of the group that the retrieved unit belongs to

community_name

String

The name of the community that the retrieved unit belongs to

alternative_code

String

The alternative code of the retrieved unit

description

String

The description of the retrieved unit

 group object response data

Name

Type

Description

id

String

The ID of the retrieved group

name

String

The name of the retrieved group

community_name

String

The name of the community that the retrieved group belongs to

alternative_code

String

The alternative code of the retrieved group

unified_codeString

The unified code of the retrieved group

Available from CRM.COM R16.2.2

description

String

The description of the retrieved group

 business unit object response data

Name

Type

Description

id

String

The ID of the retrieved business unit

name

String

The name of the retrieved business unit

codeStringThe code of the retrieved business unit
unified_codeString

The unified code of the retrieved business unit

description

String

The description of the retrieved business unit

parent_business_unit_nameStringThe name of the parent business unit that the retrieved business unit belongs to

Examples

 Example 1

HTTP Method: GET


Request:

Response:

     {
       "status":
       {
           "message": null,
           "description": null,
           "code": "OK"
       },
       "data":
       {
           "unit": null,
           "amount": 0,
           "as_of_date": "Sat Jul 05 15:49:59 EEST 2014",
           "group":
           {
               "community_name": "Main Community",
               "name": "Main Group",
               "id": "84F33366CB592BAAE7E2044D93611C6A",
               "description": "Main Group",
               "alternative_code": "das"
           },
           "product":
           {
               "product_type":
               {
                   "physical_good_type": null,
                   "service_type": "USAGE",
                   "used_for_provisioning": true,
                   "composition_method": "FLAT",
                   "classification": "SERVICES",
                   "name": "3Play ",
                   "id": "92F0AFC840E91633C5212162303BE8DF",
                   "description": "3Play Packages (Gold, Silver etc)",
                   "alternative_code": "3PLAY"
               },
               "id": "F43EBDCE48CAADEC32CB26F59904ECCD",
               "description": "Smart Card",
               "code": "Smart Card",
               "alternative_code": null
           }
       }
    }
 Example 2

HTTP Method: GET


Request:

Response:

     {
       "status":
       {
           "message": null,
           "description": null,
           "code": "OK"
       },
       "data":
       {
           "unit": null,
           "amount": 0,
           "as_of_date": "Sat Jul 05 15:49:59 EEST 2014",
           "group":
           {
               "community_name": "Main Community",
               "name": "Main Group",
               "id": "84F33366CB592BAAE7E2044D93611C6A",
               "description": "Main Group",
               "alternative_code": "das"
           },
           "product":
           {
               "product_type":
               {
                   "physical_good_type": null,
                   "service_type": "USAGE",
                   "used_for_provisioning": true,
                   "composition_method": "FLAT",
                   "classification": "SERVICES",
                   "name": "3Play ",
                   "id": "92F0AFC840E91633C5212162303BE8DF",
                   "description": "3Play Packages (Gold, Silver etc)",
                   "alternative_code": "3PLAY"
               },
               "id": "F43EBDCE48CAADEC32CB26F59904ECCD",
               "description": "Smart Card",
               "code": "Smart Card",
               "alternative_code": null
           }
       }
    }