-
Notifications
You must be signed in to change notification settings - Fork 1
/
.meshrc.yaml
171 lines (157 loc) · 6.03 KB
/
.meshrc.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
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
sources:
- name: Hashavshevet
handler:
jsonSchema:
endpoint: 'https://{env.HASHAVSHEVET_MESH_URL}/'
queryStringOptions:
indices: true
operationHeaders:
Authorization: 'Bearer {env.HASHAVSHEVET_MESH_AUTH_TOKEN}'
host: '{env.HASHAVSHEVET_MESH_URL}'
Content-Type: application/x-www-form-urlencoded
Accept: application/json
operations:
- type: Query
field: getSession
path: /api/napi
method: POST
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getSessionResponse
- type: Query
field: getCompanies
path: /CompanyListToTokenApi/TokenCompanies
method: POST
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getCompaniesResponse
- type: Query
field: getRecords
path: /ExportDataApi/exportData
method: POST
requestSchema: ./json-schemas/getRecordsRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getRecordsResponse
- type: Query
field: getTransactions
path: /ExportDataApi/exportData
method: POST
requestSchema: ./json-schemas/getTransactionsRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getTransactionsResponse
- type: Mutation
field: importTransactionsToBatch
path: /jtransApi/tmpBatch
method: POST
requestSchema: ./json-schemas/importTransactionsToBatchRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/importTransactionsToBatchResponse
- type: Mutation
field: createBatch
path: /jtransApi/newBatch
method: POST
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/createBatch
- type: Query
field: getBatch
path: /ExportDataApi/exportData
method: POST
requestSchema: ./json-schemas/getBatchRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getBatchResponse
- type: Query
field: checkBatch
path: /jtransApi/chkBatch
method: POST
requestSchema: ./json-schemas/checkBatchRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/checkBatchResponse
- type: Mutation
field: issueBatch
path: /jtransApi/issueBatch
method: POST
requestSchema: ./json-schemas/issueBatchRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/issueBatchResponse
- type: Query
field: getAccounts
path: /ExportDataApi/exportData
method: POST
requestSchema: ./json-schemas/getAccountsRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getAccountsResponse
- type: Mutation
field: importAccounts
path: /IndexApi/importIndex
method: POST
requestSchema: ./json-schemas/hashavshevetSchema.json#/definitions/importAccountsRequest
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/importAccountsResponse
# deleteAccounts (deleteIndexRecords)
# importItems (importIndexRecords)
# deleteItems (deleteIndexRecords)
- type: Query
field: getBankPageRecords
path: /ExportDataApi/exportData
method: POST
requestSchema: ./json-schemas/getBankPageRecordsRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getBankPageRecordsResponse
- type: Mutation
field: importBankPage
path: /BankPagesApi/importBankPage
method: POST
requestSchema: ./json-schemas/importBankPageRequest.json
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/importBankPageResponse
# createDocument
# showDocument
# delDocument
# issueDoc
# crmActivities
# crmActivitiesTest
- type: Query
field: getSortCodes
path: /ExportDataApi/exportData
method: POST
responseSchema: ./json-schemas/hashavshevetSchema.json#/definitions/getSortCodesResponse
transforms:
- resolversComposition:
mode: bare
compositions:
- resolver: Query.getRecords
composer: src/resolvers/getRecordsResolver
- resolver: Query.getTransactions
composer: src/resolvers/getTransactionsResolver
- resolver: Query.getBatch
composer: src/resolvers/getBatchResolver
- resolver: Query.getAccounts
composer: src/resolvers/getAccountsResolver
- resolver: Query.getBankPageRecords
composer: src/resolvers/getBankPageRecordsResolver
- resolver: Query.getSortCodes
composer: src/resolvers/getSortCodesResolver
- resolver: Mutation.importAccounts
composer: src/resolvers/importAccountsResolver
serve:
browser: false
sdk:
generateOperations:
selectionSetDepth: 5
require:
- ts-node/register/transpile-only
additionalTypeDefs: |
extend type Transaction {
batch: Batch
records: [RecordType]
creditor: Account
debtor: Account
}
extend type Batch {
transactions: [Transaction]
}
extend type RecordType {
transaction: Transaction
batch: Batch
account: Account
counterAccount: Account
}
extend type BankPageRecord {
account: Account
}
extend type importTransactionsToBatchResponse {
batch: Batch
}
extend type SortCode {
accounts: [Account]
}
extend type Account {
sortCode: SortCode
}
additionalResolvers:
- ./src/resolvers/mesh-resolvers