Skip to main content

Create Order

CreateOrderEu

This method is used to create either an invoice or a payment plan order. You specify which one to create by setting the OrderType. Please note that to be approved by the service, different order types might require additional objects to be defined.

Note:
Defining OrderType as invoice and having a PaymentPlanInformation structure within the request will result in a failed request. When you are creating orders for customers which reside in countries without unique SecurityNumbers, you have to identify them by populating as much data about the customer as possible. Then we can do an accurate scoring for them. See CustomerIdentity for more information on how to populate the CustomerIdentity structure.

Company Orders and Identification

When creating a company order for the countries which use SecurityNumber (Nordic countries), other specific customer information in the CustomerIdentity structure will be disregarded by the service. We will automatically look up the customer's address based upon the SecurityNumber. If the company has multiple establishments and you don't want the order to be sent to the first found address, you have to specify an AddressSelector in the ClientOrderInformation. Please see the GetAddresses method for more information.

For Swedish customers (B2C and B2B) it is necessary to use strong identification, such as BankID. When strong identification is enabled for your account, it is required to supply redirect URLs in the Navigation structure. Supplying URLs in other scenarios will result in a failed request.


Input

CreateOrderEuRequest

FieldRTypeDescription
CreateOrderInformation*CreateOrderInformationInformation about the order to be created
Navigation-NavigationRequired for SE when BankID is enabled

Output

CreateOrderEuResponse

FieldRTypeDescription
CreateOrderResult*CreateOrderResultInformation about the method result
ResultCode*IntegerSee Result Code table
NavigationResult-NavigationResult

Structures

CreateOrderInformation

FieldRTypeDescription
ClientOrderNumber-String(32)Your reference to the current order.
OrderRows*Array of OrderRowThe order rows that the order consists of.
CustomerIdentity*CustomerIdentityIdentity of the customer.
OrderDate*DateTimeThe date the order was placed.
AddressSelector-StringA key used to define an address when a customer has more than one address. (Only for SE, NO, DK, and FI)
CustomerReference-String(32)Customer reference. (Gets printed on the invoice.)
OrderDeliveryAddress-AddressIf order is to be delivered to an address other than the invoice, enter that address here. Special regulations concerning fraud prevention apply.
OrderType*OrderTypeSpecifying what kind of order it should be.
CreatePaymentPlanDetails-CreatePaymentPlanDetailsOnly when OrderType is PaymentPlan
CreateAccountCreditDetails-CreateAccountCreditDetailsOnly when OrderType is AccountCredit
PeppolId-String(55)Identifier for PEPPOL invoices. Format: 4 digits followed by a colon and up to 50 alphanumerical characters. For example, 0007: 5620202027.
GroupReference-StringReference used to group collective invoices. Contact Svea Payments for more information. (Not needed in a standard integration)

CustomerIdentity

FieldURTypeDescription
NationalIdNumber*-String(12)Field for entering unique identifiers for customers in certain countries. (Example (SE): Personnummer or Organisationsnummer). Will not be returned for Finnish clients.
Email--String(50)Customer email address.
PhoneNumber--String(18)Customer phone number.
IpAddress--StringCustomer IP-address.
FullName--String(40)Full name of the customer. Contains either first name + family name or company name.
Street--String(40)Customer street address.
CoAddress--String(40)Customer co-address.
ZipCode--String(5)The complete Customer zip code.
HouseNumber--StringHouse number (only applicable in certain countries).
Locality--String(20)Town of residence.
CountryCode-*String(2)A country code which defines where the customer is residing.
CustomerType-*CustomerTypeSee Enumeration
PublicKey--StringIdentifier for selecting a specific preapproved address. (Not needed in a standard integration)
IndividualIdentity--IndividualIdentityRequired for DE and NL when CustomerType is Individual
CompanyIdentity--CompanyIdentityRequired for DE and NL when CustomerType is Company

IndividualIdentity

FieldRTypeDescription
FirstName*String
LastName*String
Initials-StringOnly used in NL, “voorletters”
BirthDate*StringPerson date of birth in format YYYYMMDD.

CompanyIdentity

FieldRTypeDescription
CompanyIdentification-StringNot in use.
CompanyVATNumber*StringCompany VAT number.

CreatePaymentPlanDetails

FieldRTypeDescription
CampaignCode-IntegerPayment plan identifier. For more information, contact Svea Payments.
CoCustomerIdentity-CustomerIdentityNot in use.
SendAutomaticGiroPaymentForm*BooleanShould an autogiro-form be sent with the first notification.
FixedMonthlyAmount-Nullable of DecimalNot in use.

CreateAccountCreditDetails

FieldRTypeDescription
CampaignCode-Nullable LongAccountCredit campaign identifier.

FieldRTypeDescription
ConfirmationUrl-StringURL to a page in your webshop where the customer will be redirected after successful identification.
RejectionUrl-StringURL to a page in your webshop where the customer will be redirected if an error occurs during identification.

CreateOrderResult

FieldURTypeDescription
SveaOrderId**LongUnique Id for the created order. Used for any further webservice requests.
SveaWillBuyOrder-*BooleanDescribes whether Svea Payments will buy the order or just administrate it.
Amount-*DecimalThe approved order amount.
CustomerIdentity--CustomerIdentityShipping address.
ExpirationDate--DateTimeOrder expiration date. If the order isn’t delivered before this date the order is automatically closed and it cannot be delivered.
ClientOrderNumber--String(32)Your reference to the current order.
PendingReasons--List<String>Is set and contains identifiers if order is pending.

FieldRTypeDescription
RedirectUrl*StringLink to Svea Payments identification service.

Enumerations

CustomerType

ValueDescription
IndividualThe customer is a private individual.
CompanyThe customer is a business entity.