forked from 0xProject/0x-relayer-registry
-
Notifications
You must be signed in to change notification settings - Fork 1
/
schemas.ts
80 lines (79 loc) · 2.46 KB
/
schemas.ts
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
export const relayerSchema = {
id: '/Relayer',
type: 'object',
properties: {
name: {
type: 'string',
},
homepage_url: {
type: 'string',
format: 'uri',
description: 'url that points to the marketing / informational website',
},
app_url: {
type: 'string',
format: 'uri',
description: 'url that points to the trading interface',
},
header_img: {
type: 'string',
},
logo_img: {
type: 'string',
},
networks: {
type: 'array',
minItems: 1,
items: {
type: 'object',
properties: {
networkId: {
type: 'integer',
},
sra_http_endpoint: {
type: 'string',
format: 'uri',
description: 'HTTP Endpoint that conforms to Standard Relayer API',
},
sra_ws_endpoint: {
type: 'string',
format: 'uri',
description: 'WebSockets Endpoint that conforms to Standard Relayer API',
},
static_order_fields: {
type: 'object',
properties: {
fee_recipient_addresses: {
type: 'array',
items: {
$ref: '/Address',
},
},
maker_addresses: {
type: 'array',
items: {
$ref: '/Address',
},
},
taker_addresses: {
type: 'array',
items: {
$ref: '/Address',
},
},
},
},
},
},
},
},
required: ['name', 'homepage_url', 'networks'],
};
export const relayersSchema = {
id: '/Relayers',
title: 'Relayers',
type: 'array',
items: {
$ref: '/Relayer',
},
};