POST APIControllers/Voucher/CreateD2dVoucher

Request Information

URI Parameters

None.

Body Parameters

VoucherRequest
NameDescriptionTypeAdditional information
securityKey

string

None.

policyId

integer

None.

contactId

integer

None.

itemId

string

None.

itemName

string

None.

provinceId

integer

None.

town

string

None.

providerName

string

None.

Request Formats

application/json, text/json

Sample:
{
  "securityKey": "sample string 1",
  "policyId": 2,
  "contactId": 3,
  "itemId": "sample string 4",
  "itemName": "sample string 5",
  "provinceId": 6,
  "town": "sample string 7",
  "providerName": "sample string 8"
}

application/xml, text/xml

Sample:
<VoucherRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/mobile.oneplan.co.za.Models">
  <contactId>3</contactId>
  <itemId>sample string 4</itemId>
  <itemName>sample string 5</itemName>
  <policyId>2</policyId>
  <providerName>sample string 8</providerName>
  <provinceId>6</provinceId>
  <securityKey>sample string 1</securityKey>
  <town>sample string 7</town>
</VoucherRequest>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

ResponseOfException
NameDescriptionTypeAdditional information
Success

boolean

None.

Message

string

None.

Entity

Exception

None.

Response Formats

application/json, text/json

Sample:
{
  "Success": true,
  "Message": "sample string 2",
  "Entity": {
    "ClassName": "System.Exception",
    "Message": null,
    "Data": null,
    "InnerException": null,
    "HelpURL": "sample string 1",
    "StackTraceString": null,
    "RemoteStackTraceString": null,
    "RemoteStackIndex": 0,
    "ExceptionMethod": null,
    "HResult": 3,
    "Source": "sample string 2",
    "WatsonBuckets": null
  }
}

application/xml, text/xml

Sample:
<ResponseOfException5F2dSckg xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/OnePlan.Core">
  <Entity xmlns:d2p1="http://schemas.datacontract.org/2004/07/System">
    <ClassName xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:string" xmlns="">System.Exception</ClassName>
    <Message i:nil="true" xmlns="" />
    <Data i:nil="true" xmlns="" />
    <InnerException i:nil="true" xmlns="" />
    <HelpURL xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:string" xmlns="">sample string 1</HelpURL>
    <StackTraceString i:nil="true" xmlns="" />
    <RemoteStackTraceString i:nil="true" xmlns="" />
    <RemoteStackIndex xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:int" xmlns="">0</RemoteStackIndex>
    <ExceptionMethod i:nil="true" xmlns="" />
    <HResult xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:int" xmlns="">3</HResult>
    <Source xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:string" xmlns="">sample string 2</Source>
    <WatsonBuckets i:nil="true" xmlns="" />
  </Entity>
  <Message>sample string 2</Message>
  <Success>true</Success>
</ResponseOfException5F2dSckg>