POST api/FinalizeGiftMembership

Request Information

URI Parameters

None.

Body Parameters

FinalizeContributionRequest
NameDescriptionTypeAdditional information
PurchaseSessionKey

string

Required

AuthenticationSessionKey

string

Required

TransactionAmount

decimal number
CreditCardNumber

string
CreditCardName

string
CreditCardCVV

string
CreditCardExpirationMonth

integer

Range: inclusive between 1 and 12

CreditCardExpirationYear

integer
SourceId

integer
PaymentId

integer

Required

CreditCardType

integer

Required

AuthorizationCode

string

Required

PaymentReference

string

Required

AccountId

integer

Required

Request Formats

application/json, text/json

Sample:
{
  "PurchaseSessionKey": "sample string 1",
  "AuthenticationSessionKey": "sample string 2",
  "TransactionAmount": 3.0,
  "CreditCardNumber": "sample string 4",
  "CreditCardName": "sample string 5",
  "CreditCardCVV": "sample string 6",
  "CreditCardExpirationMonth": 7,
  "CreditCardExpirationYear": 8,
  "SourceId": 9,
  "PaymentId": 10,
  "CreditCardType": 11,
  "AuthorizationCode": "sample string 12",
  "PaymentReference": "sample string 13",
  "AccountId": 14
}

application/xml, text/xml

Sample:
<FinalizeContributionRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Contribution">
  <AccountId>14</AccountId>
  <AuthenticationSessionKey>sample string 2</AuthenticationSessionKey>
  <AuthorizationCode>sample string 12</AuthorizationCode>
  <CreditCardCVV>sample string 6</CreditCardCVV>
  <CreditCardExpirationMonth>7</CreditCardExpirationMonth>
  <CreditCardExpirationYear>8</CreditCardExpirationYear>
  <CreditCardName>sample string 5</CreditCardName>
  <CreditCardNumber>sample string 4</CreditCardNumber>
  <CreditCardType>11</CreditCardType>
  <PaymentId>10</PaymentId>
  <PaymentReference>sample string 13</PaymentReference>
  <PurchaseSessionKey>sample string 1</PurchaseSessionKey>
  <SourceId>9</SourceId>
  <TransactionAmount>3</TransactionAmount>
</FinalizeContributionRequest>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'FinalizeContributionRequest'.

Response Information

Resource Description

ApiSuccessOfGiftMembershipResult
NameDescriptionTypeAdditional information
Success

boolean
Data

GiftMembershipResult

Response Formats

application/json

Sample:
{
  "Success": true,
  "Data": {
    "MembershipDonationAdded": true,
    "AdditionalDonationAdded": true,
    "MembershipPurchaseSessionKey": "bcfvEXqcYtsT7DEKUmNtfMsdzxfyuXXvmm932owj2yYXMJS8atn9BGWo8hr6IGIZ5mew/0usdKCH9d7hjGRQFGZeaMLXM2xEctiAr1oxHRc=",
    "TotalAmountAddedToCart": 4.0,
    "PurchaseCompleted": true,
    "OrderEmailSent": true,
    "OrderNumber": 7,
    "PrimaryAddressError": true,
    "NewSessionKey": "Qkv1NapbZ0V6IuiBDbq2ulyOgELer+v3x55YP++1CrMQyPX5FsudpcIKjCGBvlC7DNzA4gQH/N2/lk2Ry5iEXQgzs4J+5sIpg43PreqnP3U=",
    "Error": [
      "sample string 1",
      "sample string 2"
    ],
    "Status": "sample string 10",
    "Message": "sample string 11"
  }
}

text/json

Sample:
{
  "Success": true,
  "Data": {
    "MembershipDonationAdded": true,
    "AdditionalDonationAdded": true,
    "MembershipPurchaseSessionKey": "RjqKzVkPpE4MStHJW66F4CPlVmbosL0rwOskgJM6zhtwunY9Q1cOfNDtTT40oC4azSURLAmXRSGNHwqFoklwbdI9D5+ArfW4Bpo17OVa+2Y=",
    "TotalAmountAddedToCart": 4.0,
    "PurchaseCompleted": true,
    "OrderEmailSent": true,
    "OrderNumber": 7,
    "PrimaryAddressError": true,
    "NewSessionKey": "7elIX6id9vDFDp/DbXBf9lixyNukSjJxD1ZrgIV5zuYVYdwzXJfrKG0Q0i+h79hwxwBOnmbEahrdxauIIT6XoAmlxPqlW278ms7cptq47lY=",
    "Error": [
      "sample string 1",
      "sample string 2"
    ],
    "Status": "sample string 10",
    "Message": "sample string 11"
  }
}

application/xml, text/xml

Sample:
<ApiSuccessOfGiftMembershipResultyx5QZ_PAX xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Api">
  <Data xmlns:d2p1="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Contribution">
    <Error xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">
      <d3p1:string>sample string 1</d3p1:string>
      <d3p1:string>sample string 2</d3p1:string>
    </Error>
    <Message xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">sample string 11</Message>
    <NewSessionKey xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">sample string 9</NewSessionKey>
    <OrderEmailSent xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">true</OrderEmailSent>
    <OrderNumber xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">7</OrderNumber>
    <PrimaryAddressError xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">true</PrimaryAddressError>
    <PurchaseCompleted xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">true</PurchaseCompleted>
    <Status xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">sample string 10</Status>
    <d2p1:AdditionalDonationAdded>true</d2p1:AdditionalDonationAdded>
    <d2p1:MembershipDonationAdded>true</d2p1:MembershipDonationAdded>
    <d2p1:MembershipPurchaseSessionKey>sample string 3</d2p1:MembershipPurchaseSessionKey>
    <d2p1:TotalAmountAddedToCart>4</d2p1:TotalAmountAddedToCart>
  </Data>
</ApiSuccessOfGiftMembershipResultyx5QZ_PAX>