@bebapps/rapyd-sdk
Version:
An un-official [Rapyd](https://rapyd.net) SDK for Node.js.
41 lines (39 loc) • 1.06 kB
text/typescript
import { Address } from '../types/Address';
export interface CreateAnOrderRequest {
/**
* ID of a coupon that is applied against this order. String starting with **coupon_**. The coupon `duration` must be **once**.
*/
coupon?: `coupon_${string}`;
/**
* ID of the customer. String starting with **cus_**.
*/
customer: `cus_${string}`;
/**
* Three-letter ISO 4217 code for the currency used in the objects in the 'items' list. Uppercase.
*/
currency: string;
/**
* Email address of the customer.
*/
email: string;
/**
* Array of line items.
*/
items: string;
/**
* A JSON object defined by the client.
*/
metadata?: object;
/**
* Address to receive the shipment. `name` and `line1` are required. See [Address Object](ref:address-object).
*/
shipping_address?: Partial<Address>;
/**
* Percentage of tax to charge. Decimal.
*/
tax_percent: number;
/**
* Merchant-defined ID for the order. If the merchant does not define an ID, Rapyd generates it.
*/
upstream_id?: string;
};