Niedermayer.ca
Published on Niedermayer.ca (https://niedermayer.ca)

Home > A New E-Commerce Protocol: Proposing a New Model for Facilitating Business to Consumer E-Commerce Transactions > Appendix A: NECP Message Format Specifications

Appendix A: NECP Message Format Specifications

Merchant Originated Message Formats

The following XML definitions are proposed for merchant-originated messages:

Shopping Cart Order Document Type Definition

<?xml version=”1.0” encoding=”UTF-8” standalone=”yes”?>

<!DOCTYPE shopping_cart [

   <!ELEMENT shopping_cart (order_id, order_details, MAC)>

   <!ELEMENT order_id      (merchant_id, order_no?,

                            timestamp?)>

   <!ELEMENT order_details (EMPTY)>

   <!ATTLIST order_details amount CDATA #REQUIRED>

   <!ATTLIST order_details shipping_included (Y|N)

                           #DEFAULT “Y”>

   <!ATTLIST order_details shipping_code #IMPLIED>

   <!ATTLIST order_details trans_type

                           (purchase|authorize|capture|credit)

                            #DEFAULT “purchase”>

   <!ELEMENT merchant_id   (#CDATA)>

   <!ELEMENT order_no      (#CDATA)>

   <!ELEMENT timestamp     (#PCDATA)>

   <!ATTLIST shopping_cart description PCDATA #IMPLIED>

   <!ATTLIST order_details currency (CA|US) #IMPLIED>

   <!ATTLIST order_details precision (2|3|4) #IMPLIED>

   <!ELEMENT MAC           (#CDATA)>

   <!ATTLIST MAC           serial_number CDATA #REQUIRED>

]>
  • Log in [1] to post comments

Cardholder Order Document Type Definition

<?xml version=”1.0” encoding=”UTF-8” standalone=”yes”?>

<!DOCTYPE cardholder_order [

   <!ELEMENT cardholder_order    (cardholder, shopping_cart,

                                  MAC)>

   <!ELEMENT cardholder          (card, identity?,

                                  destination?)>

   <!ELEMENT card                (card_number, exp_date, PIN?,

                                  CVC?)>

   <!ELEMENT card_number         (#CDATA)>

   <!ELEMENT exp_date            (#CDATA)>

   <!ELEMENT PIN                 (#CDATA)>

   <!ELEMENT CVC                 (#CDATA)>

   <!ATTLIST card                brand CDATA #IMPLIED>

   <!ELEMENT identity            (name, address?, contact?)>

   <!ELEMENT name                (title?, surname, firstname, initial?)>

   <!ELEMENT title               (Mr.|Mrs.|Ms.|Dr.|Rev.)>

   <!ELEMENT surname             (#CDATA)>

   <!ELEMENT firstname           (#CDATA)>

   <!ELEMENT initial             (#CDATA)>

   <!ELEMENT address             (street_address, city,
 province, country,

                                  postal_code)>

   <!ELEMENT street_address      (#PCDATA)>

   <!ELEMENT city                (#CDATA>

   <!ELEMENT province            (#CDATA)>

   <!ELEMENT country             (#CDATA)>

   <!ELEMENT postal_code         (#CDATA)>

   <!ELEMENT contact             (day_phone*, eve_phone*,

                                  fax_phone*, email*)

   <!ELEMENT day_phone           (#CDATA)>

   <!ELEMENT eve_phone           (#CDATA)>

   <!ELEMENT fax_phone           (#CDATA)>

   <!ELEMENT email               (#CDATA)>

   <!ELEMENT destination         (name, address)>

   <!ELEMENT shopping_cart       (order_id, order_details)>

   <!ELEMENT order_id            (merchant_id, order_no,

                                  timestamp)>

   <!ELEMENT order_details       (EMPTY)>

   <!ATTLIST order_details       amount CDATA #REQUIRED>

   <!ATTLIST order_details       trans_type

                                 (purchase|authorize|capture|

                                  credit)                            #DEFAULT “purchase”>

   <!ELEMENT merchant_id         (#CDATA)>

   <!ELEMENT order_no            (#CDATA)>

   <!ELEMENT timestamp           (#PCDATA)>

   <!ATTLIST shopping_cart       description PCDATA #IMPLIED>

   <!ATTLIST order_details       currency (CA|US) #IMPLIED>

   <!ATTLIST order_details       precision (2|3|4) #IMPLIED>

   <!ELEMENT MAC                 (#CDATA)>

   <!ATTLIST MAC                 serial_number CDATA REQUIRED>

]>
  • Log in [2] to post comments

Acquirer Originated Message Formats

The following XML definitions are proposed for merchant-originated messages:

Transaction Response Document Type Definition

<!DOCTYPE transaction_response [

   <!ELEMENT transaction_response (response, order, customer?,

                                 destination?, MAC)>

   <!ELEMENT response            (status, timestamp,

                                 auth_code?)>

   <!ELEMENT status

         (captured|authorized|denied|credited|error)>

   <!ELEMENT timestamp           (#PCDATA)>

   <!ELEMENT auth_code           (#CDATA)>

   <!ATTLIST response            prc         CDATA #IMPLIED>

   <!ATTLIST response            src         CDATA #IMPLIED>

   <!ATTLIST response            resp_msg    CDATA #IMPLIED>

   <!ATTLIST response            confidence  CDATA #IMPLIED>

   <!ELEMENT order               (merchant_id, order_no,

                                 amount)>

   <!ELEMENT merchant_id         (#PCDATA)>

   <!ELEMENT order_no            (#PCDATA)>

   <!ELEMENT amount              (#PCDATA)>

   <!ATTLIST amount              currency    CDATA #IMPLIED>

   <!ELEMENT customer            (name, address, contact?)>

   <!ELEMENT name                (title?, surname, firstname, initial?)>

   <!ELEMENT title               (Mr.|Mrs.|Ms.|Dr.|Rev.)>

   <!ELEMENT surname             (#CDATA)>

   <!ELEMENT firstname           (#CDATA)>

   <!ELEMENT initial             (#CDATA)>

   <!ELEMENT address             (street_address, city,

                                 province, country,

                                 postal_code)>

   <!ELEMENT street_address      (#PCDATA)>

   <!ELEMENT city                (#CDATA>

   <!ELEMENT province            (#CDATA)>

   <!ELEMENT country             (#CDATA)>

   <!ELEMENT postal_code         (#CDATA)>

   <!ELEMENT contact             (day_phone*, eve_phone*,

                                 fax_phone*, email*)

   <!ELEMENT day_phone           (#CDATA)>

   <!ELEMENT eve_phone           (#CDATA)>

   <!ELEMENT fax_phone           (#CDATA)>

   <!ELEMENT email               (#CDATA)>

   <!ELEMENT destination         (address)>

   <!ELEMENT MAC                 (#CDATA)>

   <!ATTLIST MAC                 serial_number CDATA

                                 #REQUIRED>

]>
  • Log in [3] to post comments

Source URL:https://niedermayer.ca/node/170

Links
[1] https://niedermayer.ca/user/login?destination=node/170%23comment-form [2] https://niedermayer.ca/user/login?destination=node/171%23comment-form [3] https://niedermayer.ca/user/login?destination=node/172%23comment-form