-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathmanifest.yaml
66 lines (65 loc) · 2.04 KB
/
manifest.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
# this is an example of the Uber API
# as a demonstration of an API spec in YAML
swagger: '2.0'
info:
x-21-github-profile-url: https://github.com/elaineo
x-21-github-project-url: https://github.com/elaineo/vending
title: Binary Options
description: Bitcoin Computer that sells 24-hour binary options on BTCUSD
version: "1.0.0"
contact:
email: [email protected]
name: elaine
url: http://elaineou.com
x-21-app-image: 'https://cdn.filepicker.io/api/file/cIKUn4hOSvqlxj7HPGAL'
x-21-category: entertainment
x-21-quick-buy: "wget -O client.py http://10.244.241.76:5000/client \npython3 client.py quote\npython3 client.py buy <up/down>"
x-21-total-price: {max: 10000, min: 1000}
x-21-keywords:
- bitcoin
- "binary options"
# the domain of the service
host: 10.244.241.76:5000
# array of all schemes that your API supports
schemes:
- http
# will be prefixed to all paths
basePath: /
paths:
/quote:
get:
summary: Get price quote
description: |
Returns the current BTCUSD rate in USD, Buy price and Sell price in satoshis.
Buying means the BTCUSD rate will be higher in 24 hours. Selling is a bet on a downward move.
responses:
200:
description: BTC/USD rate in USD
schema:
type: "string"
/buy:
get:
summary: Buy a 24-hour binary option
description: |
Specify an action for the option. The price movement will be up or down.
For example,
/buy?action=up
This buys an option indicating that the BTCUSD rate will be higher tomorrow.
parameters:
- name: action
in: query
description: up/down
required: true
type: "string"
- name: payout_address
in: query
description: bitcoin address
required: true
type: "string"
responses:
200:
description: The amount paid in satoshis and the current BTCUSD price.
schema:
type: "string"
schemes: [http]
x-21-manifest-path: /manifest