-
Notifications
You must be signed in to change notification settings - Fork 19
/
Copy pathlogistics.yaml
131 lines (131 loc) · 2.69 KB
/
logistics.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
swagger: '2.0'
info:
x-ibm-name: logistics
title: logistics
version: 2.0.0
schemes:
- https
basePath: /logistics
consumes:
- application/json
produces:
- application/json
securityDefinitions:
clientID:
description: ''
in: header
name: X-IBM-Client-Id
type: apiKey
security:
- clientID: []
x-ibm-configuration:
testable: true
enforced: true
cors:
enabled: true
gateway: datapower-api-gateway
catalogs:
sandbox:
properties:
shipping_svc_url: 'https://thinkibm-services.mybluemix.net/shipping/calculate'
properties:
shipping_svc_url:
value: 'https://thinkibm-services.mybluemix.net/shipping/calculate'
description: Location of the shipping calculator service
encoded: false
paths:
/shipping:
get:
responses:
'200':
description: 200 OK
schema:
$ref: '#/definitions/shipping'
summary: Calculate shipping costs to a destination zip code
operationId: shipping.calc
parameters:
- name: zip
type: string
required: true
in: query
description: Destination zip code.
/stores:
get:
responses:
'200':
description: 200 OK
schema:
$ref: '#/definitions/store_location'
tags:
- stores
summary: Locate store near zip code
operationId: get.stores
parameters:
- name: zip
type: string
required: true
in: query
definitions:
rates:
properties:
next_day:
type: string
example: '20.00'
two_day:
type: string
example: '17.00'
ground:
type: string
example: '8.00'
required:
- two_day
- next_day
- ground
shipping:
properties:
xyz:
$ref: '#/definitions/rates'
cek:
$ref: '#/definitions/rates'
required:
- xyz
- cek
store_location:
properties:
google_maps_link:
type: string
example: 'https://www.google.com/maps?q=34.1030032,-118.4104684'
required:
- google_maps_link
cek_shipping_rsp:
properties:
company:
type: string
rates:
type: object
properties:
next_day:
type: string
two_day:
type: string
ground:
type: string
required:
- company
- rates
xyz_shipping_rsp:
properties:
company:
type: string
rates:
type: object
properties:
next_day:
type: string
two_day:
type: string
ground:
type: string
required:
- company
- rates