POST api/FinalizePurchaseCart

Request Information

URI Parameters

None.

Body Parameters

FinalizePurchaseCartRequest
NameDescriptionTypeAdditional information
SessionKey

string

Required

NoPaymentRequired

boolean

Required

CreditCardNumber

string
CreditCardName

string
CreditCardCVV

string
CreditCardExpirationMonth

integer

Range: inclusive between 1 and 12

CreditCardExpirationYear

integer
PaymentId

integer

Required

CreditCardType

integer

Required

AuthorizationCode

string

Required

PaymentReference

string

Required

AccountId

integer

Required

Request Formats

application/json, text/json

Sample:
{
  "SessionKey": "sample string 1",
  "NoPaymentRequired": true,
  "CreditCardNumber": "sample string 3",
  "CreditCardName": "sample string 4",
  "CreditCardCVV": "sample string 5",
  "CreditCardExpirationMonth": 6,
  "CreditCardExpirationYear": 7,
  "PaymentId": 8,
  "CreditCardType": 9,
  "AuthorizationCode": "sample string 10",
  "PaymentReference": "sample string 11",
  "AccountId": 12
}

application/xml, text/xml

Sample:
<FinalizePurchaseCartRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SFMOMA.Data.Entities.Order">
  <AccountId>12</AccountId>
  <AuthorizationCode>sample string 10</AuthorizationCode>
  <CreditCardCVV>sample string 5</CreditCardCVV>
  <CreditCardExpirationMonth>6</CreditCardExpirationMonth>
  <CreditCardExpirationYear>7</CreditCardExpirationYear>
  <CreditCardName>sample string 4</CreditCardName>
  <CreditCardNumber>sample string 3</CreditCardNumber>
  <CreditCardType>9</CreditCardType>
  <NoPaymentRequired>true</NoPaymentRequired>
  <PaymentId>8</PaymentId>
  <PaymentReference>sample string 11</PaymentReference>
  <SessionKey>sample string 1</SessionKey>
</FinalizePurchaseCartRequest>

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 'FinalizePurchaseCartRequest'.

Response Information

Resource Description

ApiSuccessOfPurchaseCartResult
NameDescriptionTypeAdditional information
Success

boolean
Data

PurchaseCartResult

Response Formats

application/json

Sample:
{
  "Success": true,
  "Data": {
    "NewAccountCreated": true,
    "PurchaseCompleted": true,
    "OrderEmailSent": true,
    "OrderNumber": 4,
    "PrimaryAddressError": true,
    "NewSessionKey": "DSYptFl6GUiUbJy5sTvBCEHIdvULFGv/33Ri7+KlN3E7SfLYi2A7MGGkM0I6KBIy/Pa29bO0nBzU7jfDiIUuodjbpvk/soHkik8zLyX6XiQ=",
    "Error": [
      "sample string 1",
      "sample string 2"
    ],
    "Status": "sample string 7",
    "Message": "sample string 8"
  }
}

text/json

Sample:
{
  "Success": true,
  "Data": {
    "NewAccountCreated": true,
    "PurchaseCompleted": true,
    "OrderEmailSent": true,
    "OrderNumber": 4,
    "PrimaryAddressError": true,
    "NewSessionKey": "YBIYCyzD1W6yLArVzwubW5Aluz6Cyp6pWhFacdAP+D4MPXe5ljBUaYHvZ4ye34BAttyOq6LVKixtA1Ph/DDU5rGsLQ6cl+J8cB/iKYbuJ8Q=",
    "Error": [
      "sample string 1",
      "sample string 2"
    ],
    "Status": "sample string 7",
    "Message": "sample string 8"
  }
}

application/xml, text/xml

Sample:
<ApiSuccessOfPurchaseCartResultlnV6n2FW 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.Order">
    <d2p1:Error xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>sample string 1</d3p1:string>
      <d3p1:string>sample string 2</d3p1:string>
    </d2p1:Error>
    <d2p1:Message>sample string 8</d2p1:Message>
    <d2p1:NewSessionKey>sample string 6</d2p1:NewSessionKey>
    <d2p1:OrderEmailSent>true</d2p1:OrderEmailSent>
    <d2p1:OrderNumber>4</d2p1:OrderNumber>
    <d2p1:PrimaryAddressError>true</d2p1:PrimaryAddressError>
    <d2p1:PurchaseCompleted>true</d2p1:PurchaseCompleted>
    <d2p1:Status>sample string 7</d2p1:Status>
    <d2p1:NewAccountCreated>true</d2p1:NewAccountCreated>
  </Data>
</ApiSuccessOfPurchaseCartResultlnV6n2FW>