AddInventory

This API call will be used to add your ESN/SIM stock into the inventory. Adding Inventory using this API will just add the inventory and no other action will be performed. If you would like to add, assign or provision a ESN/SIM, you may use other APIs

End Point https://www.vcareapi.com/vcareOssApi/AddInventory/
Field (Short Description) Value/Tag Name Format Field Example Type Notes Validation rules
VENDOR ID string Vcarecorporation Required A unique Vendor ID is associated with the MVNO/OSS partner. This is used for authorization purpose and can be obtained by contacting your account manager.
USER NAME string Vcarecorporation Required A unique User name is associated with the MVNO/OSS partner. This is used for authorization purpose and can be obtained by contacting your account manager.
PASSWORD string Vcarecorporation Required This is a random string which is generated by Vcare and is tied to the MVNO/OSS user name. This is specifically used for authentication purpose and can be obtained by contacting your account manager.
PIN string 123456789 Required This is generated by Vcare to provide an additional layer of security in the Interim API. This is used for authentication purpose and can be obtained by contacting your account manager.
REFERENCE NUMBER String 123456789 Required Reference number is required to be passed with each transaction.
ESN/SIM String 8901123654789654123 Required This is the SIM/ESN which needs to be added in the inventory  
CARRIER String TMB Required Available carrier list can be otained using GetCompanyCarrier API  
MODEL ID Numeric 12 Required This can be obtained using the GetMakeModel API  
UICCID String 8901123654789654123 Conditional This is required in case of 4G  
COMPANY ID Numeric 31 Required This can be obtained using GetCompany API  
NOTES String This is a test Note Optional This is the notes field text
SELLING PRICE Number/Decimal 5/5.25 Optional This is the selling price Please pass Number or decimal value.
WHOLESALE COST Number/Decimal 3/3.25 This is the wholesale cost of the inventory Please pass Number or decimal value.
Box Number String 6464646 Required This is the box number in which the inventory have been packed  
MSL/PUK Numeric 5340 Conditional Master subsidy Lock Code or PIN unlocking Key.  
PURCHASE ORDER # String PO123698 Required This is the purchase order number
AGENT TYPE String RETAILER Required MASTER,DISTRIBUTOR,RETAILER
AGENT VALUE String safetymaster Required  
VENDOR ID String Vcare Required This is the vendor/wholeseller from whom the inventory was purchased. Available vendor id list can be otained using GetVendorAndShipperID API  
SIM CARD String Y Required Y or N  
SKU String PO123698SK Required This is the SKU number
PUK2 String 654123 Optional This is the PUK2 in case you are loading the SIM inventory  
PLANTYPEID Numeric 654123 Conditional This is the PLANTYPEID in case you are loading the CDMA device in inventory.Available plantypeid list can be otained using GetPlanType API This is a required field if in System config>>Inventory>>Add Update/Assign Plan Type For Plan Filtering is marked as Y. If this is marked as N then this is not required.
AGENT ID String John Doe Required This is the Telgoo5 user id.For the Agent/Employee who is sending the API request.  
AGENT PASSWORD String JohnDoe Conditional This is the password for the Agent Id mentioned above. This is configuration level field. If you have set the permissions for the Agent Id for the requirement of the password in API transactions then you will need to pass the Agent Password in all the XML API transaction, else if you have set the permissions to password not required then you don't need to pass the Agent Password in the XML API.  
SOURCE String API Optional Source of the order/application Expected Value:API, TABLET, IVR, POS, WEBSITE
Sample Request XML
<?xml version="1.0" encoding="utf-8"?>
<VCAREOSSAPI xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
 <CREDENTIALS>
  <VENDORID></VENDORID>
  <USERNAME></USERNAME>
  <PASSWORD></PASSWORD>
  <PIN></PIN>
  <REFERENCENUMBER></REFERENCENUMBER>
 </CREDENTIALS>
 <VCAREOSS>
  <ADDINVENTORY>
	<COMPANYID></COMPANYID>
	<ESN></ESN>
	<UICCID></UICCID>
	<SIMCARD></SIMCARD>
	<CARRIER></CARRIER>
	<PLANTYPEID></PLANTYPEID> 
	<MODELID></MODELID>
	<NOTES></NOTES>
	<SPRICE></SPRICE>
	<WPRICE></WPRICE>
	<BOX></BOX>
	<MSL></MSL>
	<PUK2></PUK2>
	<PO></PO>
	<VENDOR></VENDOR>
	<SKU></SKU>
	<AGENTTYPE></AGENTTYPE>
	<AGENTVALUE></AGENTVALUE>
	<AGENTID></AGENTID>
	<AGENTPASSWORD></AGENTPASSWORD>
	<SOURCE></SOURCE>
   </ADDINVENTORY>
 </VCAREOSS>
</VCAREOSSAPI>
List of status code, description and resolution.
Status Code Description How to Resolve?
00 SUCCESS SUCCESS
01 Error Received from Carrier. Please try again with valid data.
13 Password is invalid. Provide a valid Password.
16 Vendor not found. Wrong credentials. Please enter valid vendor credentials.
356 Agent ID cannot be blank. Please provide Agent ID as it cannot be blank.
457 Invalid Source. Please provide a valid Source. Given value is invalid for Source.
532 MSL is required. MSL is mandatory.
605 Plan Type ID Inactive. Please provide an active Plan Type ID. Given Plan Type ID is inactive.
606 Plan Type ID not found. Please provide a valid Plan Type. Given Plan Type is not available.
607 Plan Type ID is required. Please enter a Plan Type ID. Plan Type ID should not be blank.
608 Invalid Plan Type ID. Please provide a valid Plan Type ID. Given value is invalid for Plan Type ID.
Sample Response XML
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <credentials>
        <vendorId>Vcarecorporation</vendorId>
        <referenceNumber>11111</referenceNumber>
    </credentials>
       <AddInventory>
        <statusCode>00</statusCode>
        <description>SUCCESS</description>
        <errorDescription>SUCCESS</errorDescription>
        <lastInventoryId>123213</lastInventoryId>
    </AddInventory>
</VcareOssApi>

SUCCESS.
Sample Fail Response: 1
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>01</statusCode>
	<description>FAIL</description>
	<errorDescription>Error Received from Carrier.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Error Received from Carrier.
How to Resolve?: Please try again with valid data.
Sample Fail Response: 2
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>13</statusCode>
	<description>FAIL</description>
	<errorDescription>Password is invalid.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Password is invalid.
How to Resolve?: Provide a valid Password.
Sample Fail Response: 3
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>16</statusCode>
	<description>FAIL</description>
	<errorDescription>Vendor not found. Wrong credentials.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Vendor not found. Wrong credentials.
How to Resolve?: Please enter valid vendor credentials.
Sample Fail Response: 4
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>356</statusCode>
	<description>FAIL</description>
	<errorDescription>Agent ID cannot be blank.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Agent ID cannot be blank.
How to Resolve?: Please provide Agent ID as it cannot be blank.
Sample Fail Response: 5
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>457</statusCode>
	<description>FAIL</description>
	<errorDescription>Invalid Source.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Invalid Source.
How to Resolve?: Please provide a valid Source. Given value is invalid for Source.
Sample Fail Response: 6
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>532</statusCode>
	<description>FAIL</description>
	<errorDescription>MSL is required.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: MSL is required.
How to Resolve?: MSL is mandatory.
Sample Fail Response: 7
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>605</statusCode>
	<description>FAIL</description>
	<errorDescription>Plan Type ID Inactive.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Plan Type ID Inactive.
How to Resolve?: Please provide an active Plan Type ID. Given Plan Type ID is inactive.
Sample Fail Response: 8
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>606</statusCode>
	<description>FAIL</description>
	<errorDescription>Plan Type ID not found.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Plan Type ID not found.
How to Resolve?: Please provide a valid Plan Type. Given Plan Type is not available.
Sample Fail Response: 9
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>607</statusCode>
	<description>FAIL</description>
	<errorDescription>Plan Type ID is required.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Plan Type ID is required.
How to Resolve?: Please enter a Plan Type ID. Plan Type ID should not be blank.
Sample Fail Response: 10
<?xml version="1.0" encoding="utf-8"?>
<VcareOssApi xmlns="http://www.oss.vcarecorporation.com/oss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<credentials>
	<vendorId>Vcarecorporation</vendorId>
	<referenceNumber>11111</referenceNumber>
</credentials>
<AddInventory>
	<statusCode>608</statusCode>
	<description>FAIL</description>
	<errorDescription>Invalid Plan Type ID.</errorDescription>
</AddInventory>
</VcareOssApi>
Error Description: Invalid Plan Type ID.
How to Resolve?: Please provide a valid Plan Type ID. Given value is invalid for Plan Type ID.