Skip to main content

shipping.proto

path protobuffet/example/shipping/v1/shipping.proto

package protobuffet.example.shipping.v1


Messages

Address

Represents an Address that we ship to.

NameTypeDescription
street_addressstringAddress Line 1. If a unit number is present, it should prefix the street number eg. 613-54 Albert St.
citystringCity the address is within. See implementation docs for expected formatting.
statestringState the address is within. See implementation docs for expected formatting.
countrystringCountry the address is within. See implementation docs for expected formatting.
zip_codestringPostal area the address is within. See implementation docs for expected formatting.

GetQuoteRequest

Request to fetch a quote for a proposed shipment/order.

NameTypeDescription
addressAddressAddress for proposed order.
itemsrepeated protobuffet.example.carts.v1.CartItemItems within proposed order.

GetQuoteResponse

Response for a proposed shipment quote.

NameTypeDescription
cost_usdprotobuffet.example.common.types.v1.MoneyShipment quote. See implementation docs for unique responses.

ShipOrderRequest

Request to trigger a new order to be shipped.

NameTypeDescription
addressAddressAddress order should be shipped to.
itemsrepeated protobuffet.example.carts.v1.CartItemItems the proposed order contains.

ShipOrderResponse

Response for a successfully created order.

NameTypeDescription
tracking_idstringTracking ID for the created order.

Services

ShippingService

Shipment management service. This is a service created for the purpose of demonstration.

GetQuote

MethodGetQuote
RequestGetQuoteRequest
ResponseGetQuoteResponse
DescriptionFetch a quote (cost) for a proposed shipment.

ShipOrder

MethodShipOrder
RequestShipOrderRequest
ResponseShipOrderResponse
DescriptionTrigger a new order to be shipped.