Chủ Nhật, 16 tháng 8, 2020

Tickets API

 The Tickets API lets you create a technical support or refund ticket, and view or update the status of an existing ticket. For refund tickets related to physical products, you can also confirm that you’ve received a returned product.

URL

URL: https://api.clickbank.com/rest/1.3/tickets

Methods

This section provides details about the methods available within the Tickets API, including required keys and roles, output types, and supported and required parameters.

The following methods are covered in this section:

GET  /1.3/tickets/schema

This method returns the XML Schema for ticket data results.

Required Keys and Roles

  • None

Return Type

XML Schema for Ticket Data

Supported Output Types

  • application/xml

GET  /1.3/tickets/partialRefundDataSchema

This method returns the XML Schema for refund amount results.

Required Keys and Roles

  • None

Return Type

XML Schema for Partial Refund Data

Supported Output Types

  • application/xml

GET  /1.3/tickets/{id}

This method finds a ticket by its ID. It returns the ticket if it is found and is accessible by the current user. If the ticket does not exist, or the current user is not authorized to view the ticket, it returns a status code of 403.

Required Keys and Roles

  • Developer Key
  • Clerk Key
    • API Order Read Role

Return Type

Ticket Data

Supported Output Types

  • application/xml
  • application/json

GET  /1.3/tickets/count

This method counts the tickets matching the search criteria and returns the count.

Request Parameters

NameRequiredDescription
receiptNo

A receipt number. Returns a count of all tickets associated with the transaction. If the receipt number is a subscription, returns a count of all tickets associated with all rebills of that subscription.

The receipt number must be 4 or more characters long, not counting the wildcard character (%). The receipt number cannot start with the wildcard character.

statusNoThe ticket status. Valid values include:
  • open
  • reopened
  • closed
typeNoThe ticket type. Valid values include:
  • rfnd – Refund
  • cncl – Cancellation
  • tech – Technical support

Required Keys and Roles

  • Developer Key
  • Clerk Key
    • API Order Read Role

Return Type

Count of matching tickets

Supported Output Types

  • application/xml
  • application/json

GET  /1.3/tickets/list

This method searches for tickets matching the search criteria and returns a list of ticket data objects with a status code of 200. If more than 100 results are returned, it returns a status code of 206 [Partial Content]. You can use the page head parameter to view a specific page of the results.

Head Parameters

NameRequiredDescription
pageNoReturn the specified page of results. The default is page 1.

 

Request Parameters

NameRequiredDescription

closeDateFrom

No

You can use the closeDateFrom and closeDateTo parameters together to specify a date range. Tickets that were closed within the date range are returned.

The range cannot be more than 7 days in length. The date range is inclusive. The date format is yyyy-mm-dd.

closeDateTo

createDateFrom

No

You can use the createDateFrom and createDateTo parameters together to specify a date range. Tickets that were created within the date range are returned.

The range cannot be more than 7 days in length. The date range is inclusive. The date format is yyyy-mm-dd.

createDateTo
receiptNo

A receipt number. Returns all tickets associated with the transaction. If the receipt number is a subscription, returns all tickets associated with all rebills of that subscription.

The receipt number must be 4 or more characters long, not counting the wildcard character (%). The receipt number cannot start with the wildcard character.

statusNoThe ticket status. Valid values include:
  • open
  • reopened
  • closed
typeNo The ticket type. Valid values include:
  • rfnd – Refund
  • cncl – Cancellation
  • tech – Technical support

updateDateFrom

No

You can use the updateDateFrom and updateDateTo parameters together to specify a date range. Tickets that were updated within the date range are returned.

The range cannot be more than 7 days in length. The date range is inclusive. The date format is yyyy-mm-dd.

updateDateTo

Required Keys and Roles

  • Developer Key
  • Clerk Key
    • API Order Read Role

Return Type

Ticket Data

Supported Output Types

  • application/xml
  • application/json

GET  /1.3/tickets/refundAmounts/{receipt}

This method returns amounts that would be refunded for the specified refund type and value, in US Dollars.

Request Parameters

NameRequiredDescription
refundTypeYes

The type of refund. Valid values include:

  • FULL – A full refund.
  • PARTIAL_PERCENT – Refunds the percentage of the order specified by the refundAmount parameter. You must be entitled to offer partial refunds to use this value.
  • PARTIAL_AMOUNT – Refunds the amount specified by the refundAmount parameter. You must be entitled to offer partial refunds to use this value.
refundAmountRequired for partial refunds

If you specified a partial refund using the refundType parameter, the refundAmount parameter specifies the refund percentage or the refund amount in the customer's currency.

For 'PARTIAL_PERCENT' refunds, this is the percentage of the purchase amount to refund. The value must be a number between 1 and 80, with no more than two digits of precision.

For 'PARTIAL_AMOUNT' refunds, this is the amount to refund in the currency the customer used during the purchase.

skuNo

The SKU of the line item. This parameter is used to specify a specific item in orders with multiple items.

Required Keys and Roles

  • Developer Key
  • Clerk Key
    • API Order Read Role

Return Type

Partial Refund Data

Supported Output Types

  • application/xml
  • application/json

PUT  /1.3/tickets/{id}

This method lets you close a ticket, comment on a ticket, change the type of a ticket, or reopen the ticket. It returns a status code 200 and the ticket data if the action is successful, but returns a 403 if the current user is not allowed to act on the ticket or if the ticket does not exist.

Closing a ticket cancels the ticket request. For example, if you close a refund ticket, this cancels the refund request. If you do not specify an action, the only change made to the ticket will be adding your comment. Reopening is only supported for closed tickets and returns a status code of 400 for any open ticket.

Request Parameters

NameRequiredDescription
commentRequired when reopening a ticket

The comments that go along with the action, or comments on the ticket.

actionNo

The action to be taken on the specified ticket. Valid values are:

  • change
  • close
  • reopen
typeNo

Change the ticket type to the specified value. Valid values include:

  • rfnd – Refund. Partial refunds are not supported when changing ticket type.
  • cncl – Cancellation
  • tech – Technical support

Required Keys and Roles

  • Developer Key
  • Clerk Key
    • API Order Write Role

Return Type

Ticket Data

Supported Output Types

  • application/xml
  • application/json

POST  /1.3/tickets/{receipt}

This method create a ticket with the specified parameters, and returns the ticket if the ticket creation is successful. 

Request Parameters

NameRequiredDescription
reasonYesThe reason why the ticket is being opened. Each ticket type has a set of possible reasons:

CNCL

  • ticket.type.cancel.1 – I did not receive additional value for the recurring payments.
  • ticket.type.cancel.2 – I was not satisfied with the subscription / Subscription did not meet expectations.
  • ticket.type.cancel.3 – I was unable to get support from the vendor.
  • ticket.type.cancel.4 – Product was not compatible with my computer. 
  • ticket.type.cancel.5 – I am unable to afford continuing payments for this subscription.
  • ticket.type.cancel.6 – I did not realize that I accepted the terms for continuing payments.
  • ticket.type.cancel.7 – Other.
  • ticket.type.cancel.not.mobile – Product was not compatible with my mobile device.

RFND

  • ticket.type.refund.1 – I never received my product.
  • ticket.type.refund.2 – I was not satisfied with the product. / Product did not meet expectations.
  • ticket.type.refund.3 – Product was not compatible with my computer. 
  • ticket.type.refund.4 – I was unable to get technical support.
  • ticket.type.refund.5 – I did not authorize the purchase.
  • ticket.type.refund.6 – I do not recognize the purchase.
  • ticket.type.refund.7 – Duplicate purchase. / I already purchased product previously.
  • ticket.type.refund.8 – Other.
  • ticket.type.refund.returned – Product returned.
  • ticket.type.refund.not.mobile – Product was not compatible with my mobile device.

TECH

  • ticket.type.tech_support.1 – I am unable to log in.
  • ticket.type.tech_support.2 – I had problems downloading the product.
  • ticket.type.tech_support.3 – I never received a valid registration code; please send a valid code.
  • ticket.type.tech_support.4 – I can't get the product to work.
  • ticket.type.tech_support.9 – Other.
  • ticket.type.tech_support.10 – I never received my product.
typeYesThe ticket type. Valid values include:
  • rfnd – Refund. This ticket type refunds some or all of the price for the specified receipt number, and cancels all future payments for a recurring product. You must use the refundType parameter to specify the refund type.
  • cncl – Cancellation. This ticket type cancels all future payments of a recurring product but does not refund any past payments.
  • tech – Technical support.
refundAmountRequired for partial refund tickets

If you specified a partial refund using the refundType parameter, the refundAmount parameter specifies the refund amount.

For 'PARTIAL_PERCENT' refunds, this is the percentage of the purchase amount to refund. The value must be a number between 1 and 80, with no more than two digits of precision.

For 'PARTIAL_AMOUNT' refunds, this is the amount to refund in the currency the customer used during the purchase.

refundTypeRequired for refund tickets

The type of refund. Valid values include:

  • FULL – A full refund.
  • PARTIAL_PERCENT – Refunds the percentage of the order specified by the refundAmount parameter. You must be entitled to offer partial refunds to use this value.
  • PARTIAL_AMOUNT – Refunds the amount specified by the refundAmount parameter. You must be entitled to offer partial refunds to use this value.
skuRequired for orders with multiple items

The SKU for the line item. This value is used to identify individual purchases in multi-item orders.

commentNo

The comments associated with the ticket's creation.

retainSubscriptionNo

Specifies if the subscription should be retained after the refund has been processed.

 

Required Keys and Roles

  • Developer Key
  • Clerk Key
    • API Order Write Role

Return Type

Ticket Data

Supported Output Types

  • application/xml
  • application/json

POST  /1.3/tickets/{id}/returned

This method acknowledges the return of a physical item from customer, and completes the refund process for the specified ticket ID.

This call returns a status code of 204 if successful. The body of the response will be empty in this case. A status code of 403 (Forbidden) is returned if access is denied. A status code of 400 (Bad Request) is returned if the ticket isn't found or the ticket is not for a physical purchase.

Required Keys and Roles

  • Developer Key
  • Clerk Key
    • API Order Read Role
    • API Order Write Role

Return Type

Ship Notice

Supported Output Types

  • application/xml
  • application/json

Return Types

This section details the return types used by the Tickets API.

The following return types are covered in this section:

Ticket Data

Ticket Data returns use the following format:

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:cb="http://www.clickbank.com/api" version="1.0">
<xs:element name="ticketCommentData" type="ticketCommentData"/>
<xs:element name="ticketData" type="ticketData"/>
<xs:complexType name="ticketData">
<xs:sequence>
<xs:element name="ticketid" type="xs:int" nillable="true"/>
<xs:element name="receipt" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="status" type="status" nillable="true" minOccurs="0"/>
<xs:element name="type" type="ticketType" nillable="true" minOccurs="0"/>
<xs:element name="comments" type="ticketCommentData" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="openedDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="closedDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="description" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="refundType" type="refundType" nillable="true" minOccurs="0"/>
<xs:element name="refundAmount" type="xs:decimal" nillable="true" minOccurs="0"/>
<xs:element name="customerFirstName" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="customerLastName" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="email" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="emailAtOrderTime" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="expirationDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="locale" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="note" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="productItemNo" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="updateTime" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="source" type="ticketSource" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ticketCommentData">
<xs:sequence>
<xs:element name="commentId" type="xs:int" minOccurs="0"/>
<xs:element name="date" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="comment" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="action" type="ticketActionType" nillable="true" minOccurs="0"/>
<xs:element name="commentRole" type="role" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:simpleType name="status">
<xs:restriction base="xs:string">
<xs:enumeration value="OPEN"/>
<xs:enumeration value="REOPENED"/>
<xs:enumeration value="CLOSED"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketType">
<xs:restriction base="xs:string">
<xs:enumeration value="TECH_SUPPORT"/>
<xs:enumeration value="REFUND"/>
<xs:enumeration value="CANCEL"/>
<xs:enumeration value="PRODUCT_CHANGE"/>
<xs:enumeration value="ORDER_LOOKUP"/>
<xs:enumeration value="ESCALATED"/>
<xs:enumeration value="APPROVAL_IMAGE"/>
<xs:enumeration value="APPROVAL_UPSELL"/>
<xs:enumeration value="APPROVAL_CATEGORY_CHANGE"/>
<xs:enumeration value="APPROVAL_BLOG_POST"/>
<xs:enumeration value="APPROVAL_PRODUCT"/>
<xs:enumeration value="APPROVAL_ADVANCED_UPSELL"/>
<xs:enumeration value="APPROVAL_CSS_ORDERFORM"/>
<xs:enumeration value="APPROVAL_ORDER_BUMP_CUSTOM_TEXT"/>
<xs:enumeration value="CATEGORY_SUGGESTION"/>
<xs:enumeration value="BUSINESS_DEVELOPMENT"/>
<xs:enumeration value="ACCT_QUESTION_MARKETING"/>
<xs:enumeration value="ACCT_QUESTION_ACCOUNTS"/>
<xs:enumeration value="ACCT_QUESTION_ACCOUNTING"/>
<xs:enumeration value="APPROVAL_GENERIC"/>
<xs:enumeration value="SPAM"/>
<xs:enumeration value="ABUSE"/>
<xs:enumeration value="ACCOUNT_ABUSE"/>
<xs:enumeration value="SECURITY_CONCERN"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketActionType">
<xs:restriction base="xs:string">
<xs:enumeration value="ASSIGNED"/>
<xs:enumeration value="COMMENTED"/>
<xs:enumeration value="CHANGED"/>
<xs:enumeration value="CLOSED"/>
<xs:enumeration value="EXPIRED"/>
<xs:enumeration value="REOPENED"/>
<xs:enumeration value="OPENED"/>
<xs:enumeration value="APPROVED"/>
<xs:enumeration value="DISAPPROVED"/>
<xs:enumeration value="ATTACHMENT"/>
<xs:enumeration value="ADMIN_CHANGE"/>
<xs:enumeration value="REFUND_ACKED"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="role">
<xs:restriction base="xs:string">
<xs:enumeration value="VENDOR"/>
<xs:enumeration value="CUSTOMER"/>
<xs:enumeration value="CBCSR"/>
<xs:enumeration value="CBSYSTEM"/>
<xs:enumeration value="USER"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="refundType">
<xs:restriction base="xs:string">
<xs:enumeration value="FULL"/>
<xs:enumeration value="PARTIAL_PERCENT"/>
<xs:enumeration value="PARTIAL_AMOUNT"/>
<xs:enumeration value="PARTIAL_QUANTITY"/>
<xs:enumeration value="TAX"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketSource">
<xs:restriction base="xs:string">
<xs:enumeration value="API"/>
<xs:enumeration value="CUSTOMER_WAM"/>
<xs:enumeration value="UNKNOWN"/>
<xs:enumeration value="RNFDS_EMAIL"/>
<xs:enumeration value="CNCLS_EMAIL"/>
<xs:enumeration value="VENDOR_WAM"/>
<xs:enumeration value="VENDOR_ADMIN"/>
<xs:enumeration value="CSR_ADMIN"/>
<xs:enumeration value="SECURITY"/>
<xs:enumeration value="CSR_WAM"/>
<xs:enumeration value="CONVERSION_PROCESS"/>
<xs:enumeration value="BUSINESS_DEVELOPMENT_FORM"/>
<xs:enumeration value="COMMUNICATIONS_EMAIL"/>
<xs:enumeration value="ACCOUNTS_EMAIL"/>
<xs:enumeration value="CBCS_EMAIL"/>
<xs:enumeration value="ACCOUNTING_EMAIL"/>
<xs:enumeration value="WAM_ACCT_QUESTION"/>
<xs:enumeration value="WAM_WIREGROUP_DETAIL"/>
<xs:enumeration value="MARKETING_EMAIL"/>
<xs:enumeration value="PAYMENTECH_BATCH"/>
<xs:enumeration value="PYPL_JPY_CANCELLER"/>
<xs:enumeration value="ECUSTOMS"/>
<xs:enumeration value="LASHBACK"/>
<xs:enumeration value="SPAM_EMAIL"/>
<xs:enumeration value="CLICKBANK_DATABASE_SCRIPT"/>
<xs:enumeration value="API_VIRTUAL_SOURCE"/>
<xs:enumeration value="KOUNT"/>
<xs:enumeration value="CB_POWERED_PROGRAM"/>
<xs:enumeration value="CLKBANK"/>
</xs:restriction>
</xs:simpleType>
</xs:schema>

Partial Refund Data

Partial Refund Data returns use the following format:

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:cb="http://www.clickbank.com/api" version="1.0">
<xs:element name="ticketCommentData" type="ticketCommentData"/>
<xs:element name="ticketData" type="ticketData"/>
<xs:complexType name="ticketData">
<xs:sequence>
<xs:element name="ticketid" type="xs:int" nillable="true"/>
<xs:element name="receipt" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="status" type="status" nillable="true" minOccurs="0"/>
<xs:element name="type" type="ticketType" nillable="true" minOccurs="0"/>
<xs:element name="comments" type="ticketCommentData" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="openedDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="closedDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="description" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="refundType" type="refundType" nillable="true" minOccurs="0"/>
<xs:element name="refundAmount" type="xs:decimal" nillable="true" minOccurs="0"/>
<xs:element name="customerFirstName" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="customerLastName" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="email" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="emailAtOrderTime" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="expirationDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="locale" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="note" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="productItemNo" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="updateTime" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="source" type="ticketSource" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ticketCommentData">
<xs:sequence>
<xs:element name="commentId" type="xs:int" minOccurs="0"/>
<xs:element name="date" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="comment" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="action" type="ticketActionType" nillable="true" minOccurs="0"/>
<xs:element name="commentRole" type="role" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:simpleType name="status">
<xs:restriction base="xs:string">
<xs:enumeration value="OPEN"/>
<xs:enumeration value="REOPENED"/>
<xs:enumeration value="CLOSED"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketType">
<xs:restriction base="xs:string">
<xs:enumeration value="TECH_SUPPORT"/>
<xs:enumeration value="REFUND"/>
<xs:enumeration value="CANCEL"/>
<xs:enumeration value="PRODUCT_CHANGE"/>
<xs:enumeration value="ORDER_LOOKUP"/>
<xs:enumeration value="ESCALATED"/>
<xs:enumeration value="APPROVAL_IMAGE"/>
<xs:enumeration value="APPROVAL_UPSELL"/>
<xs:enumeration value="APPROVAL_CATEGORY_CHANGE"/>
<xs:enumeration value="APPROVAL_BLOG_POST"/>
<xs:enumeration value="APPROVAL_PRODUCT"/>
<xs:enumeration value="APPROVAL_ADVANCED_UPSELL"/>
<xs:enumeration value="APPROVAL_CSS_ORDERFORM"/>
<xs:enumeration value="APPROVAL_ORDER_BUMP_CUSTOM_TEXT"/>
<xs:enumeration value="CATEGORY_SUGGESTION"/>
<xs:enumeration value="BUSINESS_DEVELOPMENT"/>
<xs:enumeration value="ACCT_QUESTION_MARKETING"/>
<xs:enumeration value="ACCT_QUESTION_ACCOUNTS"/>
<xs:enumeration value="ACCT_QUESTION_ACCOUNTING"/>
<xs:enumeration value="APPROVAL_GENERIC"/>
<xs:enumeration value="SPAM"/>
<xs:enumeration value="ABUSE"/>
<xs:enumeration value="ACCOUNT_ABUSE"/>
<xs:enumeration value="SECURITY_CONCERN"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketActionType">
<xs:restriction base="xs:string">
<xs:enumeration value="ASSIGNED"/>
<xs:enumeration value="COMMENTED"/>
<xs:enumeration value="CHANGED"/>
<xs:enumeration value="CLOSED"/>
<xs:enumeration value="EXPIRED"/>
<xs:enumeration value="REOPENED"/>
<xs:enumeration value="OPENED"/>
<xs:enumeration value="APPROVED"/>
<xs:enumeration value="DISAPPROVED"/>
<xs:enumeration value="ATTACHMENT"/>
<xs:enumeration value="ADMIN_CHANGE"/>
<xs:enumeration value="REFUND_ACKED"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="role">
<xs:restriction base="xs:string">
<xs:enumeration value="VENDOR"/>
<xs:enumeration value="CUSTOMER"/>
<xs:enumeration value="CBCSR"/>
<xs:enumeration value="CBSYSTEM"/>
<xs:enumeration value="USER"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="refundType">
<xs:restriction base="xs:string">
<xs:enumeration value="FULL"/>
<xs:enumeration value="PARTIAL_PERCENT"/>
<xs:enumeration value="PARTIAL_AMOUNT"/>
<xs:enumeration value="PARTIAL_QUANTITY"/>
<xs:enumeration value="TAX"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketSource">
<xs:restriction base="xs:string">
<xs:enumeration value="API"/>
<xs:enumeration value="CUSTOMER_WAM"/>
<xs:enumeration value="UNKNOWN"/>
<xs:enumeration value="RNFDS_EMAIL"/>
<xs:enumeration value="CNCLS_EMAIL"/>
<xs:enumeration value="VENDOR_WAM"/>
<xs:enumeration value="VENDOR_ADMIN"/>
<xs:enumeration value="CSR_ADMIN"/>
<xs:enumeration value="SECURITY"/>
<xs:enumeration value="CSR_WAM"/>
<xs:enumeration value="CONVERSION_PROCESS"/>
<xs:enumeration value="BUSINESS_DEVELOPMENT_FORM"/>
<xs:enumeration value="COMMUNICATIONS_EMAIL"/>
<xs:enumeration value="ACCOUNTS_EMAIL"/>
<xs:enumeration value="CBCS_EMAIL"/>
<xs:enumeration value="ACCOUNTING_EMAIL"/>
<xs:enumeration value="WAM_ACCT_QUESTION"/>
<xs:enumeration value="WAM_WIREGROUP_DETAIL"/>
<xs:enumeration value="MARKETING_EMAIL"/>
<xs:enumeration value="PAYMENTECH_BATCH"/>
<xs:enumeration value="PYPL_JPY_CANCELLER"/>
<xs:enumeration value="ECUSTOMS"/>
<xs:enumeration value="LASHBACK"/>
<xs:enumeration value="SPAM_EMAIL"/>
<xs:enumeration value="CLICKBANK_DATABASE_SCRIPT"/>
<xs:enumeration value="API_VIRTUAL_SOURCE"/>
<xs:enumeration value="KOUNT"/>
<xs:enumeration value="CB_POWERED_PROGRAM"/>
<xs:enumeration value="CLKBANK"/>
</xs:restriction>
</xs:simpleType>
</xs:schema>

Ship Notice

Ship Notice returns use the following format:

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:cb="http://www.clickbank.com/api" version="1.0">
<xs:element name="ticketCommentData" type="ticketCommentData"/>
<xs:element name="ticketData" type="ticketData"/>
<xs:complexType name="ticketData">
<xs:sequence>
<xs:element name="ticketid" type="xs:int" nillable="true"/>
<xs:element name="receipt" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="status" type="status" nillable="true" minOccurs="0"/>
<xs:element name="type" type="ticketType" nillable="true" minOccurs="0"/>
<xs:element name="comments" type="ticketCommentData" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="openedDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="closedDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="description" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="refundType" type="refundType" nillable="true" minOccurs="0"/>
<xs:element name="refundAmount" type="xs:decimal" nillable="true" minOccurs="0"/>
<xs:element name="customerFirstName" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="customerLastName" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="email" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="emailAtOrderTime" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="expirationDate" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="locale" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="note" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="productItemNo" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="updateTime" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="source" type="ticketSource" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ticketCommentData">
<xs:sequence>
<xs:element name="commentId" type="xs:int" minOccurs="0"/>
<xs:element name="date" type="xs:dateTime" nillable="true" minOccurs="0"/>
<xs:element name="comment" type="xs:string" nillable="true" minOccurs="0"/>
<xs:element name="action" type="ticketActionType" nillable="true" minOccurs="0"/>
<xs:element name="commentRole" type="role" nillable="true" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:simpleType name="status">
<xs:restriction base="xs:string">
<xs:enumeration value="OPEN"/>
<xs:enumeration value="REOPENED"/>
<xs:enumeration value="CLOSED"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketType">
<xs:restriction base="xs:string">
<xs:enumeration value="TECH_SUPPORT"/>
<xs:enumeration value="REFUND"/>
<xs:enumeration value="CANCEL"/>
<xs:enumeration value="PRODUCT_CHANGE"/>
<xs:enumeration value="ORDER_LOOKUP"/>
<xs:enumeration value="ESCALATED"/>
<xs:enumeration value="APPROVAL_IMAGE"/>
<xs:enumeration value="APPROVAL_UPSELL"/>
<xs:enumeration value="APPROVAL_CATEGORY_CHANGE"/>
<xs:enumeration value="APPROVAL_BLOG_POST"/>
<xs:enumeration value="APPROVAL_PRODUCT"/>
<xs:enumeration value="APPROVAL_ADVANCED_UPSELL"/>
<xs:enumeration value="APPROVAL_CSS_ORDERFORM"/>
<xs:enumeration value="APPROVAL_ORDER_BUMP_CUSTOM_TEXT"/>
<xs:enumeration value="CATEGORY_SUGGESTION"/>
<xs:enumeration value="BUSINESS_DEVELOPMENT"/>
<xs:enumeration value="ACCT_QUESTION_MARKETING"/>
<xs:enumeration value="ACCT_QUESTION_ACCOUNTS"/>
<xs:enumeration value="ACCT_QUESTION_ACCOUNTING"/>
<xs:enumeration value="APPROVAL_GENERIC"/>
<xs:enumeration value="SPAM"/>
<xs:enumeration value="ABUSE"/>
<xs:enumeration value="ACCOUNT_ABUSE"/>
<xs:enumeration value="SECURITY_CONCERN"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketActionType">
<xs:restriction base="xs:string">
<xs:enumeration value="ASSIGNED"/>
<xs:enumeration value="COMMENTED"/>
<xs:enumeration value="CHANGED"/>
<xs:enumeration value="CLOSED"/>
<xs:enumeration value="EXPIRED"/>
<xs:enumeration value="REOPENED"/>
<xs:enumeration value="OPENED"/>
<xs:enumeration value="APPROVED"/>
<xs:enumeration value="DISAPPROVED"/>
<xs:enumeration value="ATTACHMENT"/>
<xs:enumeration value="ADMIN_CHANGE"/>
<xs:enumeration value="REFUND_ACKED"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="role">
<xs:restriction base="xs:string">
<xs:enumeration value="VENDOR"/>
<xs:enumeration value="CUSTOMER"/>
<xs:enumeration value="CBCSR"/>
<xs:enumeration value="CBSYSTEM"/>
<xs:enumeration value="USER"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="refundType">
<xs:restriction base="xs:string">
<xs:enumeration value="FULL"/>
<xs:enumeration value="PARTIAL_PERCENT"/>
<xs:enumeration value="PARTIAL_AMOUNT"/>
<xs:enumeration value="PARTIAL_QUANTITY"/>
<xs:enumeration value="TAX"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ticketSource">
<xs:restriction base="xs:string">
<xs:enumeration value="API"/>
<xs:enumeration value="CUSTOMER_WAM"/>
<xs:enumeration value="UNKNOWN"/>
<xs:enumeration value="RNFDS_EMAIL"/>
<xs:enumeration value="CNCLS_EMAIL"/>
<xs:enumeration value="VENDOR_WAM"/>
<xs:enumeration value="VENDOR_ADMIN"/>
<xs:enumeration value="CSR_ADMIN"/>
<xs:enumeration value="SECURITY"/>
<xs:enumeration value="CSR_WAM"/>
<xs:enumeration value="CONVERSION_PROCESS"/>
<xs:enumeration value="BUSINESS_DEVELOPMENT_FORM"/>
<xs:enumeration value="COMMUNICATIONS_EMAIL"/>
<xs:enumeration value="ACCOUNTS_EMAIL"/>
<xs:enumeration value="CBCS_EMAIL"/>
<xs:enumeration value="ACCOUNTING_EMAIL"/>
<xs:enumeration value="WAM_ACCT_QUESTION"/>
<xs:enumeration value="WAM_WIREGROUP_DETAIL"/>
<xs:enumeration value="MARKETING_EMAIL"/>
<xs:enumeration value="PAYMENTECH_BATCH"/>
<xs:enumeration value="PYPL_JPY_CANCELLER"/>
<xs:enumeration value="ECUSTOMS"/>
<xs:enumeration value="LASHBACK"/>
<xs:enumeration value="SPAM_EMAIL"/>
<xs:enumeration value="CLICKBANK_DATABASE_SCRIPT"/>
<xs:enumeration value="API_VIRTUAL_SOURCE"/>
<xs:enumeration value="KOUNT"/>
<xs:enumeration value="CB_POWERED_PROGRAM"/>
<xs:enumeration value="CLKBANK"/>
</xs:restriction>
</xs:simpleType>
</xs:schema>

Usage Information

For additional information about using the Tickets API, see the ClickBank APIs article.

Related Articles

Không có nhận xét nào: