Hmx Accounts

<back to all web services

CreatePurchaseOrder

The following routes are available for this service:
POST/api/purchaseordersCreate a new PurchaseOrder
CreatePurchaseOrder Parameters:
NameParameterData TypeRequiredDescription
UserIdbodystringNo
UserEmailbodystringNo
CreatedDatebodyDateTimeNo
VoidbodyboolNo
CouponCodebodystringNo
OrderItemsbodyList<PurchaseOrderItemDto>No
PaymentTypebodystringNo
BillingInformationDtobodyBillingInformationDtoNo
PurchaseOrderItemDto Parameters:
NameParameterData TypeRequiredDescription
IdformintNo
PurchaseOrderIdformintNo
ProductIdformstringNo
ProductNameformstringNo
QuantityformintNo
PriceformdecimalNo
DiscountDescriptionformstringNo
DiscountSourceformstringNo
DiscountformdecimalNo
CreatedDateformDateTimeNo
BillingInformationDto Parameters:
NameParameterData TypeRequiredDescription
CardNumberformstringNo
CardTypeformstringNo
ExpireMonthformintNo
ExpireYearformintNo
Cvv2formstringNo
FirstNameformstringNo
LastNameformstringNo
CityformstringNo
CountryCodeformstringNo
Line1formstringNo
PostalCodeformstringNo
StateformstringNo
CreatePurchaseOrderResponse Parameters:
NameParameterData TypeRequiredDescription
MessageformstringNo
StatusformHttpStatusCodeNo
PurchaseOrderformPurchaseOrderDtoNo
DetailsformList<Details>No
PurchaseOrderDto Parameters:
NameParameterData TypeRequiredDescription
IdformintNo
UserIdformstringNo
CreatedDateformDateTimeNo
PaymentTypeformstringNo
VoidformboolNo
PaidformboolNo
TransactionIdentifierformstringNo
CouponCodeformstringNo
OrderItemsformList<PurchaseOrderItem>No
PayerformstringNo
BillingAddressLine1formstringNo
BillingAddressCityformstringNo
BillingAddressStateformstringNo
BillingAddressPostalCodeformstringNo
BillingAddressCountryCodeformstringNo
PurchaseOrderItem Parameters:
NameParameterData TypeRequiredDescription
IdformintNo
PurchaseOrderIdformintNo
ProductIdformstringNo
ProductNameformstringNo
QuantityformintNo
PriceformdecimalNo
DiscountDescriptionformstringNo
DiscountSourceformstringNo
DiscountformdecimalNo
CreatedDateformDateTimeNo
Details Parameters:
NameParameterData TypeRequiredDescription
CodeformstringNo
FieldformstringNo
IssueformstringNo

To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /api/purchaseorders HTTP/1.1 
Host: accounts.dev.healthmonix.com 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"userId":"String","userEmail":"String","createdDate":"0001-01-01T00:00:00.0000000","void":false,"couponCode":"String","orderItems":[{"id":0,"purchaseOrderId":0,"productId":"String","productName":"String","quantity":0,"price":0,"discountDescription":"String","discountSource":"String","discount":0,"createdDate":"0001-01-01T00:00:00.0000000"}],"paymentType":"String","billingInformationDto":{"cardNumber":"String","cardType":"String","expireMonth":0,"expireYear":0,"cvv2":"String","firstName":"String","lastName":"String","city":"String","countryCode":"String","line1":"String","postalCode":"String","state":"String"}}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"message":"String","status":"Continue","purchaseOrder":{"id":0,"userId":"String","createdDate":"0001-01-01T00:00:00.0000000","paymentType":"String","void":false,"paid":false,"transactionIdentifier":"String","couponCode":"String","orderItems":[{"id":0,"purchaseOrderId":0,"productId":"String","productName":"String","quantity":0,"price":0,"discountDescription":"String","discountSource":"String","discount":0,"createdDate":"0001-01-01T00:00:00.0000000"}],"payer":"String","billingAddressLine1":"String","billingAddressCity":"String","billingAddressState":"String","billingAddressPostalCode":"String","billingAddressCountryCode":"String"},"details":[{"code":"String","field":"String","issue":"String"}]}