Catalog Item Purchases
Required Catalog Item Purchase Column Headings describes the catalog item purchase CSV column headings.
- BulkCatalogItemPurchase — Purchase catalog items for subscriptions.
- BulkGroupCatalogItemPurchase — Purchase catalog items for groups.
Column Heading | Required/Optional | Notes |
---|---|---|
SubscriberSearchData or GroupSearchData | Required |
|
OfferRequestArray | Required | Either the CatalogItemId , ProductOfferId , or ExternalId must be present. Other fields in the MtxPurchasedOfferData
MDC are optional. For more information about the MtxPurchasedOfferData MDC fields, see the discussion about MtxPurchasedOfferData. |
ChargeMethodData | Optional | All fields in the MtxChargeMethodData MDC are optional. |
EligibilityCheck | Optional | If true (default), eligibility rule evaluation will be performed. If false, eligibility rule evaluation will be skipped. |
The process_bulk_csv.py script supports CSV files in which the value in a key/value pair is an array of objects only for catalog item purchase operations. For this operation, the script reads an array of offers for the specified subscriber.
Each MtxPurchasedOfferData MDC must be in a single row. This results in a single
SubscriberId
request with multiple rows in the CSV file. For each
unique SubscriberId
, the content of each
OfferRequestArray
is combined into an array and a single JSON
request is sent to the RS Gateway .
Offer Request Array Example 1 shows example data for an offer request array for a subscription
(subId1).
SubscriberSearchData | OfferRequestArray.$ | OfferRequestArray.ProductOfferId |
---|---|---|
ExternalId+subId1 | MtxPurchasedOfferData | 1 |
ExternalId+subId1 | MtxPurchasedOfferData | 5 |
ExternalId+subId2 | MtxPurchasedOfferData | 1 |
SubscriberSearchData,OfferRequestArray.$,OfferRequestArray.CatalogItemId
ExternalId+SubId1,MtxPurchasedOfferData,23
ExternalId+SubId1,MtxPurchasedOfferData,22
ExternalId+SubId2,MtxPurchasedOfferData,23
For an offer request array, each offer must be a record in a row in the CSV file. The
column must be sorted by the SubscriberSearchData
to group each
SubscriberSearchData
value. In each row for the same
SubscriberSearchData
value, the ChargeMethodData
field values for identical fields must be the same. If the field values are not the
same, only the field value in the first row is used for the request and values for that
field in the subsequent rows for that SubscriberSearchData
value are
ignored.
ChargeMethodData
. This data results in two JSON
requests to the RS Gateway (2
records for subId1 and 1 record for subId2). If the
ChargeMethodData.PaymentMethodResourseId
value in the second row
for subId1 had been different (for example, 5081), then only the value in the first row
would be used in the request and the
ChargeMethodData.PaymentMethodResourseId
value in the second row
would be ignored. SubscriberSearchData | OfferRequestArray.$ |
---|---|
SubscriberId+subId1 | MtxPurchasedOfferData |
SubscriberId+subId1 | MtxPurchasedOfferData |
SubscriberId+subId2 | MtxPurchasedOfferData |
OfferRequest Array.CatalogItemId |
ChargeMethodData.$ | ChargeMethodData.PaymentMethodResourseId |
---|---|---|
23 | MtxChargeMethodData | 4082 |
22 | MtxChargeMethodData | 4082 |
23 | MtxChargeMethodData | 1232 |
SubscriberSearchData,OfferRequestArray.$,OfferRequestArray.CatalogItemId,ChargeMethodData.PaymentMethodResourseId
SubscriberId+SubId1,MtxPurchasedOfferData,23,MtxChargeMethodData,4082
SubscriberId+SubId1,MtxPurchasedOfferData,22,MtxChargeMethodData,4082
SubscriberId+SubId2,MtxPurchasedOfferData,23,MtxChargeMethodData,1232
For information about multi-level JSON formatting, see the discussion about multi-level JSON operations.