4. Orders

The Order is the representation of the shopping cart of your site. This API makes it possible to create, query, and list orders.

Request attributes

Name

Description

Details

ownId

Order's own id. External reference.

String (45),
mandatory
Required for the Protected Sale program.

amount

Order values.

Structured

├─currency

Currency used in the order. Possible values: BRL.

String (3),
mandatory

├─subtotals

Structure of additional order values.

Structured

├ ├─shipping

Freight value of the item, it will be added to the value of the items. Ex: R$10,32 must be informed 1032.

Integer (9),
mandatory

├ ├─addition

Additional value of the item, it will be added to the value of the items. Ex: R$10,32 must be informed 1032.

Integer (9)

├ ├─discount

Discount value of the item, it will be added to the value of the items. Ex: R$10,32 must be informed 1032.

Integer(9)

items

Structure of items order information.

Structured list

├─product

Product name.

String (250),
mandatory
Required for the Protected Sale program.

├─category

Item category. For more information see the Product Categories section.

string(256)

├─quantity

Item quantity.

integer(12),
mandatory
Required for the Protected Sale program.

├─detail

Item details.

String
mandatory
Required for the Protected Sale program.

└─price

Initial item value.
(The amount will be multiplied according to the quantity of products.) Ex cents: R $10,32 must be informed 1032.

Integer (8),
mandatory
Required for the Protected Sale program.

checkoutPreferences

Wirecard checkout configurations.

Structured

├─redirectUrls

Redirect URLs.

String (256)

├ ├─urlSuccess

URL for redirection in the success case.

String (256)

└ └─urlFailure

URL for redirection in the failure case.

String (256)

├─installments

Installments configuration.

Structured list

├ ├─quantity

Limits on the range of installments that will be accepted. Example: [1, 3].

Tupla

├ ├─discount

installment discount amount.

Integer (9)

└ └─addition

installment addition amount

Integer (9)

shippingAddress

Shipping address.

structured object,
mandatory

├─street

Street name.

String,
mandatory

├─streetNumber

Number.

String,
mandatory

├─complement

Complement.

String

├─district

District.

String,
mandatory

├─city

City.

String
mandatory

├─state

State. 2 letter abbreviation.

String (2),
mandatory

├─country

Country. 3 letter abbreviation. Example: BRA.

String (3),
mandatory

├─zipCode

Zipcode.

String (8),
mandatory

customer

The customer associated with the order. You can create an order with a existing customer or with a new customer.

Structured object

receivers

Structure of payment receivers.

Structured list

├─type

Defines the type of payment receiver, possible values:
PRIMARY,SECONDARY.

String

├─feePayor

Defines which of the receivers will pay the Wirecard fee, possible values: true or false. If the feePayor is not informed, the recipient type PRIMARY will be the payer of the Wirecard fee. If there is more than one SECONDARY 'recipient, only one of them may be the payer of the fee.

Boolean

├─moipAccount

Wirecard account Structure to inform who will receive payment amounts.

Structured

├ ├─login

Wirecard login of the payment amounts receiver.

String (256)

├ ├─fullname

Wirecard account holder name.

String (256)

├ └─id

Wirecard receiver account id.

String (16)

├─amount

Amount information structure.

Structured

├ ├─refunds

Total refunded amount.

integer(12)

├ ├─fees

Total fees amount.

integer(12)

└ └─total

Total amount received.

integer(12)

Response attributes

Name

Description

Details

id

Order identifier code.

string(16)

status

Order status. Possible values: CREATED, WAITING, PAID, NOT_PAID, REVERTED.

string

createdAt

Resource creation date.

datetime

amount

Order values.

structured

├─total

Total order amount in cents. Ex: R$10,32 must be informed
1032.

integer(12)

├─fees

Total Wirecard fee.

integer(12)

├─refunds

Total refund amount.

integer(12)

├─liquid

Total net amount.

integer(12)

├─otherReceivers

Sum of amounts received by other receivers. Used in Marketplaces.

integer(12)

├─subtotals

Structure of additional order values.

structured

└ └─items

Sum of all items values.

integer(12)

payments

Payments associated with the order. See resource for more information.

Payments collection.

refunds

Refunds associated with the order. See resource for more information.

Refunds collection.

entries

Entries associated with the order. See object for more information.

Entries collection.

events

Order events.

structured list

├─createdAt

Event creation date.

date(YYYY-MM-DD)

├─type

Events type, possible values: ORDER.CREATED, ORDER.WAITING, ORDER.PAID, ORDER.NOT_PAID, ORDER.REVERTED.

string

└─description

Event description.

string(65)

updatedAt

Resource last update date.

datetime

_links

Hypermedia link structure (HATEOAS) of the resource.

structured

├─self

Hyperlink to the resource itself.

structured

├ └─href

Hyperlink to the resource itself.

link

└─checkout

Checkout links.

object

payCheckout

Link structure.

structured

└─redirectHref

URL to access the Wirecard checkout for the user to choose the payment method: bank slip, bank transfer or credit card.

link

payCreditCard

Link structure.

structured

└─redirectHref

Wirecard checkout for credit card, safe and compliant environment by our PCI Compliance.

link

payBoleto

Link structure.

structured

└─redirectHref

URL to access Wirecard checkout and print the bank billing.

link

payOnlineBankDebitItau

Link structure.

structured

└─redirectHref

Automatic redirect URL to internet banking.

link