-
Notifications
You must be signed in to change notification settings - Fork 1
/
openapi.yml
13060 lines (12946 loc) · 435 KB
/
openapi.yml
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
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
openapi: 3.0.1
info:
title: Palantir OpenAPI
description: The Palantir REST API. Please see https://www.palantir.com/docs for
more details.
version: 1.839.0
externalDocs:
description: API Documentation
url: https://www.palantir.com/docs
paths:
/v1/attachments/upload:
post:
tags:
- OntologiesApiService
description: |
Upload an attachment to use in an action. Any attachment which has not been linked to an object via
an action within one hour after upload will be removed.
Previously mapped attachments which are not connected to any object anymore are also removed on
a biweekly basis.
The body of the request must contain the binary content of the file and the `Content-Type` header must be `application/octet-stream`.
Third-party applications using this endpoint via OAuth2 must request the
following operation scopes: `api:write-data`.
operationId: uploadAttachment
parameters:
- name: Content-Length
in: header
description: The size in bytes of the file content being uploaded.
required: true
schema:
$ref: '#/components/schemas/ContentLength'
- name: Content-Type
in: header
description: The media type of the file being uploaded.
required: true
schema:
$ref: '#/components/schemas/ContentType'
- name: filename
in: query
description: The name of the file being uploaded.
required: true
schema:
$ref: '#/components/schemas/Filename'
example: My Image.jpeg
requestBody:
content:
'*/*':
schema:
type: string
format: binary
required: true
responses:
"200":
description: Success response.
content:
application/json:
schema:
$ref: '#/components/schemas/Attachment'
example:
filename: My Image.jpeg
mediaType: image/jpeg
rid: ri.attachments.main.attachment.bb32154e-e043-4b00-9461-93136ca96b6f
sizeBytes: 393469
security:
- BearerAuth: []
/v1/attachments/{attachmentRid}:
get:
tags:
- OntologiesApiService
description: |
Get the metadata of an attachment.
Third-party applications using this endpoint via OAuth2 must request the
following operation scopes: `api:read-data`.
operationId: getAttachment
parameters:
- name: attachmentRid
in: path
description: The RID of the attachment.
required: true
schema:
$ref: '#/components/schemas/AttachmentRid'
example: ri.attachments.main.attachment.bb32154e-e043-4b00-9461-93136ca96b6f
responses:
"200":
description: Success response.
content:
application/json:
schema:
$ref: '#/components/schemas/Attachment'
example:
filename: My Image.jpeg
mediaType: image/jpeg
rid: ri.attachments.main.attachment.bb32154e-e043-4b00-9461-93136ca96b6f
sizeBytes: 393469
security:
- BearerAuth: []
/v1/attachments/{attachmentRid}/content:
get:
tags:
- OntologiesApiService
description: |
Get the content of an attachment.
Third-party applications using this endpoint via OAuth2 must request the
following operation scopes: `api:read-data`.
operationId: getAttachmentContent
parameters:
- name: attachmentRid
in: path
description: The RID of the attachment.
required: true
schema:
$ref: '#/components/schemas/AttachmentRid'
example: ri.attachments.main.attachment.bb32154e-e043-4b00-9461-93136ca96b6f
responses:
"200":
description: Success response.
content:
'*/*':
schema:
type: string
format: binary
security:
- BearerAuth: []
/v1/datasets:
post:
tags:
- DatasetsApiService
description: |
Creates a new Dataset. A default branch - `master` for most enrollments - will be created on the Dataset.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-write`.
operationId: createDataset
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateDatasetRequest'
example:
name: My Dataset
parentFolderRid: ri.foundry.main.folder.bfe58487-4c56-4c58-aba7-25defd6163c4
required: true
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/Dataset'
example:
path: /Empyrean Airlines/My Important Project/My Dataset
rid: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
security:
- BearerAuth: []
/v1/datasets/{datasetRid}:
get:
tags:
- DatasetsApiService
description: |
Gets the Dataset with the given DatasetRid.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-read`.
operationId: getDataset
parameters:
- name: datasetRid
in: path
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/Dataset'
example:
name: My Dataset
parentFolderRid: ri.foundry.main.folder.bfe58487-4c56-4c58-aba7-25defd6163c4
rid: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/branches:
get:
tags:
- DatasetsApiService
description: |
Lists the Branches of a Dataset.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-read`.
operationId: listBranches
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset on which to list
Branches.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
- name: pageSize
in: query
description: |
The desired size of the page to be returned. Defaults to 1,000.
See [page sizes](/docs/foundry/api/general/overview/paging/#page-sizes) for details.
required: false
schema:
$ref: '#/components/schemas/PageSize'
- name: pageToken
in: query
required: false
schema:
$ref: '#/components/schemas/PageToken'
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/ListBranchesResponse'
example:
data:
- branchId: master
transactionRid: ri.foundry.main.transaction.0a0207cb-26b7-415b-bc80-66a3aa3933f4
- branchId: test-v2
transactionRid: ri.foundry.main.transaction.fc9feb4b-34e4-4bfd-9e4f-b6425fbea85f
- branchId: my-branch
nextPageToken: v1.VGhlcmUgaXMgc28gbXVjaCBsZWZ0IHRvIGJ1aWxkIC0gcGFsYW50aXIuY29tL2NhcmVlcnMv
security:
- BearerAuth: []
post:
tags:
- DatasetsApiService
description: |
Creates a branch on an existing dataset. A branch may optionally point to a (committed) transaction.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-write`.
operationId: createBranch
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset on which to create
the Branch.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateBranchRequest'
example:
branchId: my-branch
required: true
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/Branch'
example:
branchId: my-branch
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/branches/{branchId}:
get:
tags:
- DatasetsApiService
description: |
Get a Branch of a Dataset.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-read`.
operationId: getBranch
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset that contains the
Branch.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
- name: branchId
in: path
description: The identifier (name) of the Branch.
required: true
schema:
$ref: '#/components/schemas/BranchId'
example: master
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/Branch'
example:
branchId: master
transactionRid: ri.foundry.main.transaction.0a0207cb-26b7-415b-bc80-66a3aa3933f4
security:
- BearerAuth: []
delete:
tags:
- DatasetsApiService
description: |
Deletes the Branch with the given BranchId.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-write`.
operationId: deleteBranch
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset that contains the
Branch.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
- name: branchId
in: path
description: The identifier (name) of the Branch.
required: true
schema:
$ref: '#/components/schemas/BranchId'
example: my-branch
responses:
"204":
description: Branch deleted.
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/files:
get:
tags:
- DatasetsApiService
description: "Lists Files contained in a Dataset. By default files are listed\
\ on the latest view of the default \nbranch - `master` for most enrollments.\n\
\n#### Advanced Usage\n\nSee [Datasets Core Concepts](/docs/foundry/data-integration/datasets/)\
\ for details on using branches and transactions.\n\nTo **list files on a\
\ specific Branch** specify the Branch's identifier as `branchId`. This will\
\ include the most\nrecent version of all files since the latest snapshot\
\ transaction, or the earliest ancestor transaction of the \nbranch if there\
\ are no snapshot transactions.\n\nTo **list files on the resolved view of\
\ a transaction** specify the Transaction's resource identifier\nas `endTransactionRid`.\
\ This will include the most recent version of all files since the latest\
\ snapshot\ntransaction, or the earliest ancestor transaction if there are\
\ no snapshot transactions.\n\nTo **list files on the resolved view of a range\
\ of transactions** specify the the start transaction's resource\nidentifier\
\ as `startTransactionRid` and the end transaction's resource identifier as\
\ `endTransactionRid`. This\nwill include the most recent version of all files\
\ since the `startTransactionRid` up to the `endTransactionRid`.\nNote that\
\ an intermediate snapshot transaction will remove all files from the view.\
\ Behavior is undefined when \nthe start and end transactions do not belong\
\ to the same root-to-leaf path.\n\nTo **list files on a specific transaction**\
\ specify the Transaction's resource identifier as both the \n`startTransactionRid`\
\ and `endTransactionRid`. This will include only files that were modified\
\ as part of that\nTransaction.\n\nThird-party applications using this endpoint\
\ via OAuth2 must request the following operation scope: `api:datasets-read`.\n"
operationId: listFiles
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset on which to list
Files.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
- name: branchId
in: query
description: The identifier (name) of the Branch on which to list Files. Defaults
to `master` for most enrollments.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: startTransactionRid
in: query
description: The Resource Identifier (RID) of the start Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: endTransactionRid
in: query
description: The Resource Identifier (RID) of the end Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: pageSize
in: query
description: |
The desired size of the page to be returned. Defaults to 1,000.
See [page sizes](/docs/foundry/api/general/overview/paging/#page-sizes) for details.
required: false
schema:
$ref: '#/components/schemas/PageSize'
- name: pageToken
in: query
required: false
schema:
$ref: '#/components/schemas/PageToken'
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/ListFilesResponse'
example:
data:
- path: q3-data/my-file.csv
sizeBytes: "74930"
transactionRid: ri.foundry.main.transaction.bf9515c2-02d4-4703-8f84-c3b3c190254d
updatedTime: 2022-10-10T16:44:55.192Z
- path: q2-data/my-file.csv
sizeBytes: "47819"
transactionRid: ri.foundry.main.transaction.d8db1cfc-9f8b-4bad-9d8c-00bd818a37c5
updatedTime: 2022-07-12T10:12:50.919Z
- path: q2-data/my-other-file.csv
sizeBytes: "55320"
transactionRid: ri.foundry.main.transaction.d8db1cfc-9f8b-4bad-9d8c-00bd818a37c5
updatedTime: 2022-07-12T10:12:46.112Z
nextPageToken: v1.VGhlcmUgaXMgc28gbXVjaCBsZWZ0IHRvIGJ1aWxkIC0gcGFsYW50aXIuY29tL2NhcmVlcnMv
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/files/{filePath}:
get:
tags:
- DatasetsApiService
description: "Gets metadata about a File contained in a Dataset. By default\
\ this retrieves the file's metadata from the latest\nview of the default\
\ branch - `master` for most enrollments.\n\n#### Advanced Usage\n\nSee [Datasets\
\ Core Concepts](/docs/foundry/data-integration/datasets/) for details on\
\ using branches and transactions. \n\nTo **get a file's metadata from a specific\
\ Branch** specify the Branch's identifier as `branchId`. This will \nretrieve\
\ metadata for the most recent version of the file since the latest snapshot\
\ transaction, or the earliest\nancestor transaction of the branch if there\
\ are no snapshot transactions.\n\nTo **get a file's metadata from the resolved\
\ view of a transaction** specify the Transaction's resource identifier\n\
as `endTransactionRid`. This will retrieve metadata for the most recent version\
\ of the file since the latest snapshot\ntransaction, or the earliest ancestor\
\ transaction if there are no snapshot transactions.\n\nTo **get a file's\
\ metadata from the resolved view of a range of transactions** specify the\
\ the start transaction's\nresource identifier as `startTransactionRid` and\
\ the end transaction's resource identifier as `endTransactionRid`.\nThis\
\ will retrieve metadata for the most recent version of the file since the\
\ `startTransactionRid` up to the \n`endTransactionRid`. Behavior is undefined\
\ when the start and end transactions do not belong to the same root-to-leaf\
\ path.\n\nTo **get a file's metadata from a specific transaction** specify\
\ the Transaction's resource identifier as both the \n`startTransactionRid`\
\ and `endTransactionRid`.\n\nThird-party applications using this endpoint\
\ via OAuth2 must request the following operation scope: `api:datasets-read`.\n"
operationId: getFileMetadata
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset that contains the
File.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
- name: filePath
in: path
description: The File's path within the Dataset.
required: true
schema:
$ref: '#/components/schemas/FilePath'
example: q3-data%2fmy-file.csv
- name: branchId
in: query
description: The identifier (name) of the Branch that contains the File. Defaults
to `master` for most enrollments.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: startTransactionRid
in: query
description: The Resource Identifier (RID) of the start Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: endTransactionRid
in: query
description: The Resource Identifier (RID) of the end Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/File'
example:
path: q3-data/my-file.csv
sizeBytes: "74930"
transactionRid: ri.foundry.main.transaction.bf9515c2-02d4-4703-8f84-c3b3c190254d
updatedTime: 2022-10-10T16:44:55.192Z
security:
- BearerAuth: []
delete:
tags:
- DatasetsApiService
description: "Deletes a File from a Dataset. By default the file is deleted\
\ in a new transaction on the default \nbranch - `master` for most enrollments.\
\ The file will still be visible on historical views.\n\n#### Advanced Usage\n\
\ \nSee [Datasets Core Concepts](/docs/foundry/data-integration/datasets/)\
\ for details on using branches and transactions.\n\nTo **delete a File from\
\ a specific Branch** specify the Branch's identifier as `branchId`. A new\
\ delete Transaction \nwill be created and committed on this branch.\n\nTo\
\ **delete a File using a manually opened Transaction**, specify the Transaction's\
\ resource identifier \nas `transactionRid`. The transaction must be of type\
\ `DELETE`. This is useful for deleting multiple files in a\nsingle transaction.\
\ See [createTransaction](/docs/foundry/api/datasets-resources/transactions/create-transaction/)\
\ to \nopen a transaction.\n\nThird-party applications using this endpoint\
\ via OAuth2 must request the following operation scope: `api:datasets-write`.\n"
operationId: deleteFile
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset on which to delete
the File.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
- name: filePath
in: path
description: The File path within the Dataset.
required: true
schema:
$ref: '#/components/schemas/FilePath'
example: q3-data%2fmy-file.csv
- name: branchId
in: query
description: The identifier (name) of the Branch on which to delete the File.
Defaults to `master` for most enrollments.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: transactionRid
in: query
description: The Resource Identifier (RID) of the open delete Transaction
on which to delete the File.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
responses:
"204":
description: File deleted.
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/files/{filePath}/content:
get:
tags:
- DatasetsApiService
description: "Gets the content of a File contained in a Dataset. By default\
\ this retrieves the file's content from the latest\nview of the default branch\
\ - `master` for most enrollments.\n\n#### Advanced Usage\n\nSee [Datasets\
\ Core Concepts](/docs/foundry/data-integration/datasets/) for details on\
\ using branches and transactions. \n\nTo **get a file's content from a specific\
\ Branch** specify the Branch's identifier as `branchId`. This will \nretrieve\
\ the content for the most recent version of the file since the latest snapshot\
\ transaction, or the\nearliest ancestor transaction of the branch if there\
\ are no snapshot transactions.\n\nTo **get a file's content from the resolved\
\ view of a transaction** specify the Transaction's resource identifier\n\
as `endTransactionRid`. This will retrieve the content for the most recent\
\ version of the file since the latest\nsnapshot transaction, or the earliest\
\ ancestor transaction if there are no snapshot transactions.\n\nTo **get\
\ a file's content from the resolved view of a range of transactions** specify\
\ the the start transaction's\nresource identifier as `startTransactionRid`\
\ and the end transaction's resource identifier as `endTransactionRid`.\n\
This will retrieve the content for the most recent version of the file since\
\ the `startTransactionRid` up to the \n`endTransactionRid`. Note that an\
\ intermediate snapshot transaction will remove all files from the view. Behavior\n\
is undefined when the start and end transactions do not belong to the same\
\ root-to-leaf path.\n\nTo **get a file's content from a specific transaction**\
\ specify the Transaction's resource identifier as both the \n`startTransactionRid`\
\ and `endTransactionRid`.\n\nThird-party applications using this endpoint\
\ via OAuth2 must request the following operation scope: `api:datasets-read`.\n"
operationId: getFileContent
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset that contains the
File.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
- name: filePath
in: path
description: The File's path within the Dataset.
required: true
schema:
$ref: '#/components/schemas/FilePath'
example: q3-data%2fmy-file.csv
- name: branchId
in: query
description: The identifier (name) of the Branch that contains the File. Defaults
to `master` for most enrollments.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: startTransactionRid
in: query
description: The Resource Identifier (RID) of the start Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: endTransactionRid
in: query
description: The Resource Identifier (RID) of the end Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
responses:
"200":
description: ""
content:
'*/*':
schema:
type: string
format: binary
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/files:upload:
post:
tags:
- DatasetsApiService
description: "Uploads a File to an existing Dataset.\nThe body of the request\
\ must contain the binary content of the file and the `Content-Type` header\
\ must be `application/octet-stream`.\n\nBy default the file is uploaded to\
\ a new transaction on the default branch - `master` for most enrollments.\n\
If the file already exists only the most recent version will be visible in\
\ the updated view.\n\n#### Advanced Usage\n\nSee [Datasets Core Concepts](/docs/foundry/data-integration/datasets/)\
\ for details on using branches and transactions. \n\nTo **upload a file to\
\ a specific Branch** specify the Branch's identifier as `branchId`. A new\
\ transaction will \nbe created and committed on this branch. By default the\
\ TransactionType will be `UPDATE`, to override this\ndefault specify `transactionType`\
\ in addition to `branchId`. \nSee [createBranch](/docs/foundry/api/datasets-resources/branches/create-branch/)\
\ to create a custom branch.\n\nTo **upload a file on a manually opened transaction**\
\ specify the Transaction's resource identifier as\n`transactionRid`. This\
\ is useful for uploading multiple files in a single transaction. \nSee [createTransaction](/docs/foundry/api/datasets-resources/transactions/create-transaction/)\
\ to open a transaction.\n\nThird-party applications using this endpoint via\
\ OAuth2 must request the following operation scope: `api:datasets-write`.\n"
operationId: uploadFile
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset on which to upload
the File.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
- name: filePath
in: query
description: The File's path within the Dataset.
required: true
schema:
$ref: '#/components/schemas/FilePath'
example: q3-data%2fmy-file.csv
- name: branchId
in: query
description: The identifier (name) of the Branch on which to upload the File.
Defaults to `master` for most enrollments.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: transactionType
in: query
description: The type of the Transaction to create when using branchId. Defaults
to `UPDATE`.
required: false
schema:
$ref: '#/components/schemas/TransactionType'
- name: transactionRid
in: query
description: The Resource Identifier (RID) of the open Transaction on which
to upload the File.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
requestBody:
content:
'*/*':
schema:
type: string
format: binary
required: true
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/File'
example:
path: q3-data/my-file.csv
sizeBytes: "74930"
transactionRid: ri.foundry.main.transaction.bf9515c2-02d4-4703-8f84-c3b3c190254d
updatedTime: 2022-10-10T16:44:55.192Z
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/readTable:
get:
tags:
- DatasetsApiService
description: |
Gets the content of a dataset as a table in the specified format.
This endpoint currently does not support views (Virtual datasets composed of other datasets).
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-read`.
operationId: readTable
parameters:
- name: datasetRid
in: path
description: |
The RID of the Dataset.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
- name: branchId
in: query
description: The identifier (name) of the Branch.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: startTransactionRid
in: query
description: The Resource Identifier (RID) of the start Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: endTransactionRid
in: query
description: The Resource Identifier (RID) of the end Transaction.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: format
in: query
description: |
The export format. Must be `ARROW` or `CSV`.
required: true
schema:
$ref: '#/components/schemas/TableExportFormat'
example: CSV
- name: columns
in: query
description: |
A subset of the dataset columns to include in the result. Defaults to all columns.
required: false
schema:
type: array
items:
type: string
- name: rowLimit
in: query
description: |
A limit on the number of rows to return. Note that row ordering is non-deterministic.
required: false
schema:
type: integer
responses:
"200":
description: The content stream.
content:
'*/*':
schema:
type: string
format: binary
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/schema:
get:
tags:
- DatasetsApiService
description: |
Retrieves the Schema for a Dataset and Branch, if it exists.
operationId: getSchema
parameters:
- name: datasetRid
in: path
description: |
The RID of the Dataset.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
- name: branchId
in: query
description: |
The ID of the Branch.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: transactionRid
in: query
description: |
The TransactionRid that contains the Schema.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: preview
in: query
required: false
schema:
$ref: '#/components/schemas/PreviewMode'
example: true
responses:
"200":
description: ""
content:
application/json:
schema:
type: object
"204":
description: No Content
security:
- BearerAuth: []
put:
tags:
- DatasetsApiService
description: |
Puts a Schema on an existing Dataset and Branch.
operationId: putSchema
parameters:
- name: datasetRid
in: path
description: |
The RID of the Dataset on which to put the Schema.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
- name: branchId
in: query
description: |
The ID of the Branch on which to put the Schema.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: preview
in: query
required: false
schema:
$ref: '#/components/schemas/PreviewMode'
example: true
requestBody:
content:
application/json:
schema:
type: object
required: true
responses:
"204":
description: ""
security:
- BearerAuth: []
delete:
tags:
- DatasetsApiService
description: |
Deletes the Schema from a Dataset and Branch.
operationId: deleteSchema
parameters:
- name: datasetRid
in: path
description: |
The RID of the Dataset on which to delete the schema.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
- name: branchId
in: query
description: |
The ID of the Branch on which to delete the schema.
required: false
schema:
$ref: '#/components/schemas/BranchId'
- name: transactionRid
in: query
description: |
The RID of the Transaction on which to delete the schema.
required: false
schema:
$ref: '#/components/schemas/TransactionRid'
- name: preview
in: query
required: false
schema:
$ref: '#/components/schemas/PreviewMode'
example: true
responses:
"204":
description: Schema deleted.
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/transactions:
post:
tags:
- DatasetsApiService
description: |
Creates a Transaction on a Branch of a Dataset.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-write`.
operationId: createTransaction
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset on which to create
the Transaction.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
- name: branchId
in: query
description: |
The identifier (name) of the Branch on which to create the Transaction. Defaults to `master` for most enrollments.
required: false
schema:
$ref: '#/components/schemas/BranchId'
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateTransactionRequest'
example:
transactionType: SNAPSHOT
required: true
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/Transaction'
example:
createdTime: 2022-10-10T12:23:11.152Z
rid: ri.foundry.main.transaction.abffc380-ea68-4843-9be1-9f44d2565496
status: OPEN
transactionType: SNAPSHOT
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/transactions/{transactionRid}:
get:
tags:
- DatasetsApiService
description: |
Gets a Transaction of a Dataset.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-read`.
operationId: getTransaction
parameters:
- name: datasetRid
in: path
description: The Resource Identifier (RID) of the Dataset that contains the
Transaction.
required: true
schema:
$ref: '#/components/schemas/DatasetRid'
example: ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da
- name: transactionRid
in: path
description: The Resource Identifier (RID) of the Transaction.
required: true
schema:
$ref: '#/components/schemas/TransactionRid'
example: ri.foundry.main.transaction.abffc380-ea68-4843-9be1-9f44d2565496
responses:
"200":
description: ""
content:
application/json:
schema:
$ref: '#/components/schemas/Transaction'
example:
createdTime: 2022-10-10T12:20:15.166Z
rid: ri.foundry.main.transaction.abffc380-ea68-4843-9be1-9f44d2565496
status: OPEN
transactionType: SNAPSHOT
security:
- BearerAuth: []
/v1/datasets/{datasetRid}/transactions/{transactionRid}/abort:
post:
tags:
- DatasetsApiService
description: |
Aborts an open Transaction. File modifications made on this Transaction are not preserved and the Branch is
not updated.
Third-party applications using this endpoint via OAuth2 must request the following operation scope: `api:datasets-write`.
operationId: abortTransaction
parameters:
- name: datasetRid
in: path