Welcome‎ > ‎Version 3‎ > ‎Publisher Api‎ > ‎Methods‎ > ‎4 - Publisher Related‎ > ‎

Add Pending Credit

** The Authentication of this method will change.  If you'd like to be notified of the change, please post in the comment section below so you can be notified before the change. **

Adds a pending credit to the system. 

Method: POST /api/v3/publisher/pendingcredit

Authentication: oauth
 
Post
Required Form Name Data Type Explanation
Yes
AwardTriggerType
string The event that must occur before the pending credit is awarded to the consumer.  One of {ForNextPurchase, AfterNextPurchase, OnSignUp}.
No
CampaignKey
string An optional identifier for the marketing campaign driving this pending credit.
Yes CreditType
string The type of credit to award the consumer.  One of {Marketing, CustomerSupport}.
Yes
CurrencyValue
decimal The amount of the pending credit in the specified IsoCurrencyCode.
Yes
EmailAddress
string The email address of the consumer to award the pending credit to when the trigger event occurs.
No
ExpirationDate
datetime The expiration date of the pending credit.  If not provided, the pending credit will never expire.
Yes
IsoCurrencyCode
string The three character ISO currency code for the CurrencyValue (e.g. USD)

Returns
base response fields


Sample Request:

POST http://api.groupcommerce.com/api/v3/publisher/pendingcredit

Form: AwardTriggerType=ForNextPurchase&CreditType=Marketing&CurrencyValue=10&EmailAddress=pendingcredits%40groupcommerce.com&IsoCurrencyCode=USD&CampaignKey=heart-of-it-all&ExpirationDate=1406088000


OAuth oauth_signature="s4HAnbIB%2BDy5N5Ef%2BB9r604qYHI%3D", oauth_nonce="1393901", oauth_timestamp="1347495062", oauth_consumer_key="eeb6b959-b854-4ad1-b563-e801c83cf81d", oauth_signature_method="HMAC-SHA1", oauth_version="1.0"


Sample JSON Response:

{
    "errors": [],
    "lastPublished": "/Date(1347495119208)/",
    "success": true,
    "version": "3"
}


Sample XML Response:

<addPendingCreditResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <errors />
  <lastPublished>2012-09-13T00:11:02.1167985Z</lastPublished>
  <success>true</success>
  <version>3</version>
</addPendingCreditResponse>
Comments