Show / Hide Table of Contents

Class OrderService

Class representing a set of order-related functionality.

Inheritance
System.Object
EasyPostService
OrderService
Implements
IEasyPostService
IDisposable
Inherited Members
EasyPostService.Client
EasyPostService.RequestAsync<T>(Method, String, CancellationToken, Nullable<Dictionary<String, Object>>, Nullable<String>, ApiVersion)
EasyPostService.RequestAsync(Method, String, CancellationToken, Nullable<Dictionary<String, Object>>, ApiVersion)
EasyPostService.Dispose()
EasyPostService.Dispose(Boolean)
Namespace: EasyPost.Services
Assembly: EasyPost.dll
Syntax
public class OrderService : EasyPostService, IEasyPostService

Methods

| Improve this Doc View Source

Buy(String, Rate, CancellationToken)

Purchase the Shipments within an Order. Related API documentation.

Declaration
public async Task<Order> Buy(string id, Rate rate, CancellationToken cancellationToken = null)
Parameters
Type Name Description
System.String id

The ID of the Order to purchase.

Rate rate

The Rate to purchase the Shipments with.

CancellationToken cancellationToken

to use for the HTTP request.

Returns
Type Description
Task<Order>

An updated Order.

| Improve this Doc View Source

Buy(String, Buy, CancellationToken)

Purchase the Shipments within an Order. Related API documentation.

Declaration
public async Task<Order> Buy(string id, Buy parameters, CancellationToken cancellationToken = null)
Parameters
Type Name Description
System.String id

The ID of the Order to purchase.

Buy parameters

Buy parameters set.

CancellationToken cancellationToken

to use for the HTTP request.

Returns
Type Description
Task<Order>

An updated Order.

| Improve this Doc View Source

Buy(String, String, String, CancellationToken)

Purchase the Shipments within an Order. Related API documentation.

Declaration
public async Task<Order> Buy(string id, string withCarrier, string withService, CancellationToken cancellationToken = null)
Parameters
Type Name Description
System.String id

The ID of the Order to purchase.

System.String withCarrier

The carrier to purchase the Shipments with.

System.String withService

The service to purchase the Shipments with.

CancellationToken cancellationToken

to use for the HTTP request.

Returns
Type Description
Task<Order>

An updated Order.

| Improve this Doc View Source

Create(Dictionary<String, Object>, CancellationToken)

Create an Order. Related API documentation.

Declaration
public async Task<Order> Create(Dictionary<string, object> parameters, CancellationToken cancellationToken = null)
Parameters
Type Name Description
Dictionary<System.String, System.Object> parameters

Data to use to create the Order.

CancellationToken cancellationToken

to use for the HTTP request.

Returns
Type Description
Task<Order>

An Order object.

| Improve this Doc View Source

Create(Create, CancellationToken)

Create an Order. Related API documentation.

Declaration
public async Task<Order> Create(Create parameters, CancellationToken cancellationToken = null)
Parameters
Type Name Description
Create parameters

Data to use to create the Order.

CancellationToken cancellationToken

to use for the HTTP request.

Returns
Type Description
Task<Order>

An Order object.

| Improve this Doc View Source

RefreshRates(String, CancellationToken)

Repopulate the Rates for an Order.

Declaration
public async Task<Order> RefreshRates(string id, CancellationToken cancellationToken = null)
Parameters
Type Name Description
System.String id

The ID of the Order to refresh the Rates for.

CancellationToken cancellationToken

to use for the HTTP request.

Returns
Type Description
Task<Order>

An updated Order with refreshed Rates.

| Improve this Doc View Source

Retrieve(String, CancellationToken)

Retrieve an Order. Related API documentation.

Declaration
public async Task<Order> Retrieve(string id, CancellationToken cancellationToken = null)
Parameters
Type Name Description
System.String id

The ID of the Order to retrieve.

CancellationToken cancellationToken

to use for the HTTP request.

Returns
Type Description
Task<Order>

An Order object.

Implements

IEasyPostService
IDisposable
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX