vgs_api_client 0.0.1.alpha202205271226 → 0.0.1.alpha202205272111

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7550d328892698eb930bea04bbea7c281721593415ce0b2e3baaa1966bf3ba05
4
- data.tar.gz: d95737723e4073aff12413520bd525b8befb47467f18d899b5991e4190a3ed49
3
+ metadata.gz: 2c002bdf5a526c4634dc23d5ad9074b6194c09f086e576311738aec7a3a61aa6
4
+ data.tar.gz: 5d2f9924ad206fbe7bf5147e118eeb1ade67dc6a4e0c6bd3d3e39c766f2623f0
5
5
  SHA512:
6
- metadata.gz: 3cbf7f157eff2176bcdc9237e2480bf55eaa0aad140487969311ac1d2e6e1cab3fcd5809ab6afbea98ac49965c80ef4496737eaaaf88a9832ec9e050de4ff1f6
7
- data.tar.gz: 8efdf504e1c71463364beefb08e11d4802fffe48e60a0ae7f0e66fbc7e37edfb2aa1a3c7c9c22647a44ce822db6061b403c614e489ad3c0c93891d9a1916616f
6
+ metadata.gz: c94ea93bdbd4a681b2b96430f5d72e0c0c7705ca380dce13898a0b2c5de2c030ef3f7366e4fbacf52fdcd65609952a6b7d250af5bfbbee1eda439e66bcd2d073
7
+ data.tar.gz: cf69308fca8ff06a5a679e26eb15081dca9bc5688f94ddcc956bb6496199ea051d60a16cb6d993d5d9ad2e96706d68734b70553782bf5e5bf3bef23f2ca84b5e
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.1.alpha202205271226
1
+ 0.0.1.alpha202205272111
data/api.yaml CHANGED
@@ -3,7 +3,7 @@ info:
3
3
  title: Vault HTTP API
4
4
  description: |
5
5
  The VGS Vault HTTP API is used for storing, retrieving, and managing sensitive data (aka Tokenization) within a VGS Vault.
6
-
6
+
7
7
  The VGS API is organized around REST. Our API is built with a predictable resource-oriented structure, uses JSON-encoded requests and responses, follows standard HTTP verbs/responses, and uses industry standard authentication.
8
8
 
9
9
  ## What is VGS
@@ -17,13 +17,13 @@ info:
17
17
  **Zero Data** is a unique method invented by VGS in 2016 that securely stores data like Tokenization, however it also removes the customer’s environment from PCI scope completely providing maximum security, and minimum compliance scope. [Get started with Zero Data](https://www.verygoodsecurity.com/docs/getting-started/before-you-start).
18
18
 
19
19
  Additionally, for scenarios where neither technology is a complete solution, for instance with legacy systems, VGS provides a compliance product which guarantees customers are able to meet their compliance needs no matter what may happen. [Get started with Control](https://www.verygoodsecurity.com/docs/control).
20
-
20
+
21
21
  ## Learn about Tokenization
22
-
22
+
23
23
  - [Create an Account for Free Tokenization](https://dashboard.verygoodsecurity.com/tokenization)
24
24
  - [Try a Tokenization Demo](https://www.verygoodsecurity.com/docs/tokenization/getting-started)
25
25
  - [Install a Tokenization SDK](https://www.verygoodsecurity.com/docs/tokenization/client-libraries)
26
-
26
+
27
27
  ### Authentication
28
28
 
29
29
  This API uses `Basic` authentication.
@@ -35,9 +35,9 @@ info:
35
35
  [Docs » Guides » Access credentials](https://www.verygoodsecurity.com/docs/settings/access-credentials)
36
36
 
37
37
  ## Resource Limits
38
-
38
+
39
39
  ### Data Limits
40
-
40
+
41
41
  This API allows storing data up to 32MB in size.
42
42
 
43
43
  ### Rate Limiting
@@ -80,13 +80,14 @@ info:
80
80
  contact:
81
81
  email: support@verygoodsecurity.com
82
82
  x-logo:
83
- url: images/vgs-logo.png
83
+ url: https://www.verygoodsecurity.com/img/press-and-assets/vgs-logo-color.png
84
84
  href: https://www.verygoodsecurity.com
85
85
  altText: VGS Logo
86
+ termsOfService: https://www.verygoodsecurity.com/terms-and-conditions
86
87
 
87
88
  externalDocs:
88
- description: Find out more about VGS
89
- url: https://www.verygoodsecurity.com/
89
+ description: Visit the VGS documentation homepage
90
+ url: https://www.verygoodsecurity.com/docs/
90
91
 
91
92
  servers:
92
93
  - url: https://api.sandbox.verygoodvault.com
@@ -111,9 +112,307 @@ x-tagGroups:
111
112
  - aliases
112
113
 
113
114
  security:
114
- - basicAuth: []
115
+ - BasicAuth: []
115
116
 
116
117
  paths:
118
+ /functions:
119
+ post:
120
+ operationId: createFunction
121
+ summary: Creates a new function
122
+ security:
123
+ - OAuth2: [functions:write]
124
+ tags:
125
+ - functions
126
+ description: |
127
+ Creates a new function.
128
+ requestBody:
129
+ content:
130
+ application/json:
131
+ schema:
132
+ $ref: '#/components/schemas/CreateFunctionRequest'
133
+ examples:
134
+ CreateFunctionRequestOne:
135
+ summary: Create a new function
136
+ value:
137
+ data:
138
+ - src: |
139
+ def process(input, ctx):
140
+ return input
141
+ lang: larky
142
+ name: my-function
143
+ responses:
144
+ '201':
145
+ description: Created
146
+ content:
147
+ application/json:
148
+ schema:
149
+ type: object
150
+ properties:
151
+ data:
152
+ type: array
153
+ items:
154
+ $ref: '#/components/schemas/Function'
155
+ description: A retrieved function.
156
+ minItems: 1
157
+ maxItems: 20
158
+ examples:
159
+ CreateFunctionResponseOne:
160
+ summary: Create a new function
161
+ value:
162
+ data:
163
+ - src: |
164
+ def process(input, ctx):
165
+ return input
166
+ lang: larky
167
+ name: my-function-46Juzcyx
168
+ hash: bc1f0c3322091740cead407000af9acc692e7fefd0d96446e07900dcd0f8e308
169
+
170
+ default:
171
+ $ref: '#/components/responses/ApiErrorsResponse'
172
+ get:
173
+ operationId: listFunctions
174
+ summary: Lists all functions
175
+ security:
176
+ - OAuth2: [functions:read]
177
+ tags:
178
+ - functions
179
+ description: |
180
+ Lists all functions
181
+ responses:
182
+ '200':
183
+ description: OK
184
+ content:
185
+ application/json:
186
+ schema:
187
+ type: object
188
+ properties:
189
+ data:
190
+ type: array
191
+ items:
192
+ $ref: '#/components/schemas/Function'
193
+ description: A retrieved function.
194
+ minItems: 1
195
+ maxItems: 20
196
+ default:
197
+ $ref: '#/components/responses/ApiErrorsResponse'
198
+
199
+ /functions/{functionName}:
200
+ parameters:
201
+ - $ref: '#/components/parameters/functionName'
202
+ get:
203
+ operationId: getFunction
204
+ tags:
205
+ - functions
206
+ summary: Retrieve a single function
207
+ security:
208
+ - OAuth2: [functions:read]
209
+ description: |
210
+ Retrieves a function
211
+ parameters:
212
+ - $ref: '#/components/parameters/functionName'
213
+ responses:
214
+ '200':
215
+ description: OK
216
+ content:
217
+ application/json:
218
+ schema:
219
+ type: object
220
+ properties:
221
+ data:
222
+ type: array
223
+ items:
224
+ $ref: '#/components/schemas/Function'
225
+ description: The retrieved function.
226
+ minItems: 1
227
+ maxItems: 1
228
+ examples:
229
+ UpdateFunctionResponseOne:
230
+ summary: Update a new function
231
+ value:
232
+ data:
233
+ - src: |
234
+ def process(input, ctx):
235
+ return input
236
+ lang: larky
237
+ name: my-function-46Juzcyx
238
+ hash: bc1f0c3322091740cead407000af9acc692e7fefd0d96446e07900dcd0f8e308
239
+ default:
240
+ $ref: '#/components/responses/ApiErrorsResponse'
241
+
242
+ put:
243
+ operationId: updateFunction
244
+ tags:
245
+ - functions
246
+ summary: Update function
247
+ security:
248
+ - OAuth2: [functions:write]
249
+ description: |
250
+ Update an existing function definition
251
+ requestBody:
252
+ content:
253
+ application/json:
254
+ schema:
255
+ $ref: '#/components/schemas/UpdateFunctionRequestPayload'
256
+ responses:
257
+ '200':
258
+ description: No Content
259
+ default:
260
+ $ref: '#/components/responses/ApiErrorsResponse'
261
+
262
+ delete:
263
+ operationId: deleteFunction
264
+ tags:
265
+ - functions
266
+ summary: Deletes a function
267
+ security:
268
+ - OAuth2: [functions:write]
269
+ description: |
270
+ Removes a single alias.
271
+ parameters:
272
+ - $ref: '#/components/parameters/functionName'
273
+ responses:
274
+ '204':
275
+ description: No Content
276
+ default:
277
+ $ref: '#/components/responses/ApiErrorsResponse'
278
+
279
+ /functions/{functionName}/invocations:
280
+ parameters:
281
+ - $ref: '#/components/parameters/functionName'
282
+ post:
283
+ operationId: invokeFunction
284
+ tags:
285
+ - functions
286
+ summary: Invoke a function
287
+ description: |
288
+ Invokes a function
289
+ parameters:
290
+ - $ref: '#/components/parameters/functionName'
291
+ requestBody:
292
+ content:
293
+ "application/x-www-form-urlencoded":
294
+ schema:
295
+ type: string
296
+ example:
297
+ hello world
298
+ description: Stream of bytes up to XX KB in size
299
+ "text/plain":
300
+ schema:
301
+ type: string
302
+ format: byte
303
+ example:
304
+ aGVsbG8gd29ybGQK
305
+ description: Stream of bytes base64 encoded up to XX KB in size
306
+ application/http:
307
+ schema:
308
+ type: object
309
+ properties:
310
+ method:
311
+ type: string
312
+ enum:
313
+ - POST
314
+ - PATCH
315
+ - DELETE
316
+ - PUT
317
+ - GET
318
+ - HEAD
319
+ uri:
320
+ type: string
321
+ format: uri
322
+ example: https://example.com/software/htp/cics/index.html
323
+ version:
324
+ type: string
325
+ enum:
326
+ - "1.0"
327
+ - "1.1"
328
+ headers:
329
+ type: array
330
+ items:
331
+ type: object
332
+ properties:
333
+ key:
334
+ type: string
335
+ value:
336
+ type: string
337
+ body:
338
+ type: string
339
+ format: string
340
+
341
+ description: https://www.iana.org/assignments/media-types/media-types.xhtml
342
+ examples:
343
+ InvokeFunction1:
344
+ summary: Invoke a function with a HTTP request payload
345
+ value:
346
+ method: GET
347
+ uri: https://example.com/software/htp/cics/index.html
348
+ version: 1.0
349
+
350
+ "*/*":
351
+ schema:
352
+ type: string
353
+ format: binary?
354
+ description: Stream of bytes up to XX KB in size
355
+ responses:
356
+ '200':
357
+ description: OK
358
+ content:
359
+ application/http:
360
+ schema:
361
+ type: object
362
+ properties:
363
+ method:
364
+ type: string
365
+ enum:
366
+ - POST
367
+ - PATCH
368
+ - DELETE
369
+ - PUT
370
+ - GET
371
+ - HEAD
372
+ uri:
373
+ type: string
374
+ format: uri
375
+ example: https://example.com/software/htp/cics/index.html
376
+ version:
377
+ type: string
378
+ enum:
379
+ - "1.0"
380
+ - "1.1"
381
+ headers:
382
+ type: array
383
+ items:
384
+ type: object
385
+ properties:
386
+ key:
387
+ type: string
388
+ value:
389
+ type: string
390
+ body:
391
+ type: string
392
+ format: string
393
+
394
+ description: https://www.iana.org/assignments/media-types/media-types.xhtml
395
+ example:
396
+ method: POST
397
+ uri: https://example.com/software/htp/cics/index.html
398
+ version: 1.0
399
+ headers:
400
+ - key: Content-Type
401
+ value: text/plain
402
+ "text/plain":
403
+ schema:
404
+ type: string
405
+ description: Stream of bytes base64 up to XX KB in size
406
+ example:
407
+ aGVsbG8gd29ybGQK
408
+ "*":
409
+ schema:
410
+ type: string
411
+ format: binary
412
+ description: Stream of bytes up to XX KB in size
413
+ default:
414
+ $ref: '#/components/responses/ApiErrorsResponse'
415
+
117
416
  /aliases:
118
417
  post:
119
418
  operationId: createAliases
@@ -345,16 +644,41 @@ paths:
345
644
  -X DELETE \
346
645
  -u "$USERNAME:$PASSWORD"
347
646
 
348
-
349
647
  components:
350
648
 
351
649
  # See the following links for details:
352
650
  # - https://swagger.io/docs/specification/authentication/basic-authentication/
651
+ # https://swagger.io/docs/specification/authentication/
353
652
  securitySchemes:
354
- basicAuth:
653
+ BasicAuth:
355
654
  type: http
356
655
  scheme: basic
357
- description: The default authentication schema.
656
+ description: |
657
+ The default authentication scheme for [Data API](#data-apis) based requests
658
+ is [Basic authentication](https://en.wikipedia.org/wiki/Basic_access_authentication).
659
+ OAuth2:
660
+ type: oauth2
661
+ flows:
662
+ authorizationCode:
663
+ authorizationUrl: https://auth.verygoodsecurity.com/auth/realms/vgs/protocol/openid-connect/auth
664
+ tokenUrl: https://auth.verygoodsecurity.io/auth/realms/vgs/protocol/openid-connect/token
665
+ scopes:
666
+ credentials:read: Read vault credentials without reading secrets
667
+ credentials:write: Add, delete and manage credentials of vault
668
+ routes:read: Read your vault routes
669
+ routes:write: Create, read, update, delete your vault routes
670
+ vaults:read: Read details of your vaults
671
+ vaults:write: Read, create, update and delete your vaults
672
+ upstreams:read: Read your upstreams for SFTP routes
673
+ upstreams:write: Create and update upstreams for SFTP routes
674
+ certificates:read: Read certificates setup for your routes
675
+ certificates:write: Upload and delete certificates for routes
676
+ hostnames:read: Read/List Custom Hostnames of your vault routes
677
+ hostnames:write: Create/Delete Custom Hostname of your vault routes
678
+ functions:read: Read/List Functions
679
+ functions:write: Create/Delete Functions
680
+ description: |
681
+ The default authentication schema for [Management API](#management-apis) based requests.
358
682
 
359
683
  parameters:
360
684
  alias:
@@ -366,6 +690,15 @@ components:
366
690
  type: string
367
691
  example: tok_sandbox_bhtsCwFUzoJMw9rWUfEV5e
368
692
 
693
+ functionName:
694
+ name: functionName
695
+ in: path
696
+ required: true
697
+ description: Name of function to operate on
698
+ schema:
699
+ type: string
700
+ example: my-function-46Juzcyx
701
+
369
702
  responses:
370
703
  ApiErrorsResponse:
371
704
  description: Something went wrong
@@ -497,7 +830,7 @@ components:
497
830
  default: PERSISTENT
498
831
  description: |
499
832
  Storage medium to use.
500
-
833
+
501
834
  VOLATILE results in data being persisted into an in-memory data store for one hour which is required for PCI compliant storage of card security code data.
502
835
  required:
503
836
  - value
@@ -532,3 +865,78 @@ components:
532
865
  - classifiers
533
866
  required:
534
867
  - data
868
+
869
+ CreateFunctionRequest:
870
+ type: object
871
+ properties:
872
+ data:
873
+ type: array
874
+ items:
875
+ oneOf:
876
+ - $ref: '#/components/schemas/CreateFunctionRequestPayload'
877
+ minItems: 1
878
+ maxItems: 20
879
+ required:
880
+ - data
881
+
882
+ CreateFunctionRequestPayload:
883
+ type: object
884
+ properties:
885
+ name:
886
+ type: string
887
+ description: Prefix to name your function
888
+ pattern: "[a-zA-Z]+([A-Za-z0-9\\-_]){5,28}[a-zA-Z0-9]"
889
+ example: my-function
890
+ src:
891
+ type: string
892
+ description: Definition of function body
893
+ example: |
894
+ def process(input, ctx):
895
+ return input
896
+ lang:
897
+ type: string
898
+ enum:
899
+ - larky
900
+ default: larky
901
+ description: |
902
+ Language to write your function in.
903
+ required:
904
+ - name
905
+ - src
906
+
907
+ UpdateFunctionRequestPayload:
908
+ type: object
909
+ properties:
910
+ src:
911
+ type: string
912
+ description: Definition of function body
913
+ example: |
914
+ def process(input, ctx):
915
+ return input
916
+ required:
917
+ - src
918
+
919
+ Function:
920
+ type: object
921
+ properties:
922
+ name:
923
+ type: string
924
+ example: my-function-46Juzcyx
925
+ src:
926
+ type: string
927
+ description: Definition of function body
928
+ example: |
929
+ def process(input, ctx):
930
+ return input
931
+ lang:
932
+ type: string
933
+ enum:
934
+ - larky
935
+ default: larky
936
+ description: |
937
+ Language to write your function in.
938
+ hash:
939
+ type: string
940
+ description: SHA256 representation of the function definition
941
+ example: bc1f0c3322091740cead407000af9acc692e7fefd0d96446e07900dcd0f8e308
942
+
@@ -64,7 +64,7 @@ module VgsApiClient
64
64
  return_type = opts[:debug_return_type] || 'InlineResponse201'
65
65
 
66
66
  # auth_names
67
- auth_names = opts[:debug_auth_names] || ['basicAuth']
67
+ auth_names = opts[:debug_auth_names] || ['BasicAuth']
68
68
 
69
69
  new_options = opts.merge(
70
70
  :operation => :"AliasesApi.create_aliases",
@@ -127,7 +127,7 @@ module VgsApiClient
127
127
  return_type = opts[:debug_return_type]
128
128
 
129
129
  # auth_names
130
- auth_names = opts[:debug_auth_names] || ['basicAuth']
130
+ auth_names = opts[:debug_auth_names] || ['BasicAuth']
131
131
 
132
132
  new_options = opts.merge(
133
133
  :operation => :"AliasesApi.delete_alias",
@@ -190,7 +190,7 @@ module VgsApiClient
190
190
  return_type = opts[:debug_return_type] || 'InlineResponse2001'
191
191
 
192
192
  # auth_names
193
- auth_names = opts[:debug_auth_names] || ['basicAuth']
193
+ auth_names = opts[:debug_auth_names] || ['BasicAuth']
194
194
 
195
195
  new_options = opts.merge(
196
196
  :operation => :"AliasesApi.reveal_alias",
@@ -254,7 +254,7 @@ module VgsApiClient
254
254
  return_type = opts[:debug_return_type] || 'InlineResponse200'
255
255
 
256
256
  # auth_names
257
- auth_names = opts[:debug_auth_names] || ['basicAuth']
257
+ auth_names = opts[:debug_auth_names] || ['BasicAuth']
258
258
 
259
259
  new_options = opts.merge(
260
260
  :operation => :"AliasesApi.reveal_multiple_aliases",
@@ -324,7 +324,7 @@ module VgsApiClient
324
324
  return_type = opts[:debug_return_type]
325
325
 
326
326
  # auth_names
327
- auth_names = opts[:debug_auth_names] || ['basicAuth']
327
+ auth_names = opts[:debug_auth_names] || ['BasicAuth']
328
328
 
329
329
  new_options = opts.merge(
330
330
  :operation => :"AliasesApi.update_alias",