1swagger: '2.0' 2info: 3 title: SEMAPHORE 4 description: Semaphore API 5 version: "2.2.0" 6 7host: localhost:3000 8 9consumes: 10 - application/json 11produces: 12 - application/json 13 - text/plain; charset=utf-8 14 15tags: 16 - name: authentication 17 description: Authentication, Logout & API Tokens 18 - name: project 19 description: Everything related to a project 20 - name: user 21 description: User-related API 22 23schemes: 24 - http 25 - https 26 27basePath: /api 28 29definitions: 30 31 Pong: 32 type: string 33 x-example: pong 34 35 Login: 36 type: object 37 properties: 38 auth: 39 type: string 40 description: Username/Email address 41 x-example: user@semaphore.com 42 password: 43 type: string 44 format: password 45 description: Password 46 47 UserRequest: 48 type: object 49 properties: 50 name: 51 type: string 52 x-example: Integration Test User 53 example: Integration Test User 54 username: 55 type: string 56 x-example: test-user 57 example: test-user 58 email: 59 type: string 60 x-example: test@ansiblesemaphore.test 61 example: test@ansiblesemaphore.test 62 alert: 63 type: boolean 64 admin: 65 type: boolean 66 67 UserPutRequest: 68 type: object 69 properties: 70 name: 71 type: string 72 x-example: Integration Test User2 73 example: Integration Test User2 74 username: 75 type: string 76 x-example: test-user2 77 example: test-user2 78 email: 79 type: string 80 x-example: test2@ansiblesemaphore.test 81 example: test2@ansiblesemaphore.test 82 alert: 83 type: boolean 84 admin: 85 type: boolean 86 User: 87 type: object 88 properties: 89 id: 90 type: integer 91 minimum: 1 92 name: 93 type: string 94 username: 95 type: string 96 email: 97 type: string 98 created: 99 type: string 100 pattern: ^\d{4}-(?:0[0-9]{1}|1[0-2]{1})-[0-9]{2}T\d{2}:\d{2}:\d{2}Z$ 101 alert: 102 type: boolean 103 admin: 104 type: boolean 105 106 APIToken: 107 type: object 108 properties: 109 id: 110 type: string 111 created: 112 type: string 113 pattern: ^\d{4}-(?:0[0-9]{1}|1[0-2]{1})-[0-9]{2}T\d{2}:\d{2}:\d{2}Z$ 114 expired: 115 type: boolean 116 user_id: 117 type: integer 118 minimum: 1 119 120 ProjectRequest: 121 type: object 122 properties: 123 name: 124 type: string 125 alert: 126 type: boolean 127 Project: 128 type: object 129 properties: 130 id: 131 type: integer 132 minimum: 1 133 name: 134 type: string 135 created: 136 type: string 137 pattern: ^\d{4}-(?:0[0-9]{1}|1[0-2]{1})-[0-9]{2}T\d{2}:\d{2}:\d{2}Z$ 138 alert: 139 type: boolean 140 141 AccessKeyRequest: 142 type: object 143 properties: 144 name: 145 type: string 146 type: 147 type: string 148 enum: [ssh, aws, gcloud, do] 149 project_id: 150 type: integer 151 minimum: 1 152 x-example: 2 153 key: 154 type: string 155 secret: 156 type: string 157 example: test 158 AccessKey: 159 type: object 160 properties: 161 id: 162 type: integer 163 name: 164 type: string 165 type: 166 type: string 167 enum: [ssh, aws, gcloud, do] 168 project_id: 169 type: integer 170 key: 171 type: string 172 secret: 173 type: string 174 175 EnvironmentRequest: 176 type: object 177 properties: 178 name: 179 type: string 180 project_id: 181 type: integer 182 minimum: 1 183 password: 184 type: string 185 json: 186 type: string 187 Environment: 188 type: object 189 properties: 190 id: 191 type: integer 192 minimum: 1 193 name: 194 type: string 195 project_id: 196 type: integer 197 minimum: 1 198 password: 199 type: string 200 json: 201 type: string 202 203 InventoryRequest: 204 type: object 205 properties: 206 name: 207 type: string 208 project_id: 209 type: integer 210 minimum: 1 211 inventory: 212 type: string 213 key_id: 214 type: integer 215 minimum: 1 216 ssh_key_id: 217 type: integer 218 minimum: 1 219 type: 220 type: string 221 enum: [static, file] 222 Inventory: 223 type: object 224 properties: 225 id: 226 type: integer 227 name: 228 type: string 229 project_id: 230 type: integer 231 inventory: 232 type: string 233 key_id: 234 type: integer 235 ssh_key_id: 236 type: integer 237 type: 238 type: string 239 enum: [static, file] 240 241 RepositoryRequest: 242 type: object 243 properties: 244 name: 245 type: string 246 project_id: 247 type: integer 248 git_url: 249 type: string 250 ssh_key_id: 251 type: integer 252 Repository: 253 type: object 254 properties: 255 id: 256 type: integer 257 name: 258 type: string 259 project_id: 260 type: integer 261 git_url: 262 type: string 263 ssh_key_id: 264 type: integer 265 266 Task: 267 type: object 268 properties: 269 id: 270 type: integer 271 example: 23 272 template_id: 273 type: integer 274 status: 275 type: string 276 debug: 277 type: boolean 278 playbook: 279 type: string 280 environment: 281 type: string 282 TaskOutput: 283 type: object 284 properties: 285 task_id: 286 type: integer 287 example: 23 288 task: 289 type: string 290 time: 291 type: string 292 format: date-time 293 output: 294 type: string 295 296 TemplateRequest: 297 type: object 298 properties: 299 ssh_key_id: 300 type: integer 301 minimum: 1 302 project_id: 303 type: integer 304 minimum: 1 305 inventory_id: 306 type: integer 307 minimum: 1 308 repository_id: 309 type: integer 310 minimum: 1 311 environment_id: 312 type: integer 313 minimum: 1 314 alias: 315 type: string 316 playbook: 317 type: string 318 arguments: 319 type: string 320 override_args: 321 type: boolean 322 Template: 323 type: object 324 properties: 325 id: 326 type: integer 327 minimum: 1 328 ssh_key_id: 329 type: integer 330 minimum: 1 331 project_id: 332 type: integer 333 minimum: 1 334 inventory_id: 335 type: integer 336 minimum: 1 337 repository_id: 338 type: integer 339 environment_id: 340 type: integer 341 minimum: 1 342 alias: 343 type: string 344 playbook: 345 type: string 346 arguments: 347 type: string 348 override_args: 349 type: boolean 350 351 Event: 352 type: object 353 properties: 354 project_id: 355 type: integer 356 object_id: 357 type: 358 - integer 359 - 'null' 360 object_type: 361 type: 362 - string 363 - 'null' 364 description: 365 type: string 366 367 InfoType: 368 type: object 369 properties: 370 version: 371 type: string 372 updateBody: 373 type: string 374 update: 375 type: object 376 properties: 377 tag_name: 378 type: string 379 380securityDefinitions: 381 cookie: 382 type: apiKey 383 name: Cookie 384 in: header 385 bearer: 386 type: apiKey 387 name: Authorization 388 in: header 389 390security: 391 - bearer: [] 392 - cookie: [] 393 394parameters: 395 project_id: 396 name: project_id 397 description: Project ID 398 in: path 399 type: integer 400 required: true 401 x-example: 1 402 user_id: 403 name: user_id 404 description: User ID 405 in: path 406 type: integer 407 required: true 408 x-example: 2 409 key_id: 410 name: key_id 411 description: key ID 412 in: path 413 type: integer 414 required: true 415 x-example: 3 416 repository_id: 417 name: repository_id 418 description: repository ID 419 in: path 420 type: integer 421 required: true 422 x-example: 4 423 inventory_id: 424 name: inventory_id 425 description: inventory ID 426 in: path 427 type: integer 428 required: true 429 x-example: 5 430 environment_id: 431 name: environment_id 432 description: environment ID 433 in: path 434 type: integer 435 required: true 436 x-example: 6 437 template_id: 438 name: template_id 439 description: template ID 440 in: path 441 type: integer 442 required: true 443 x-example: 7 444 task_id: 445 name: task_id 446 description: task ID 447 in: path 448 type: integer 449 required: true 450 x-example: 8 451 452paths: 453 /ping: 454 get: 455 summary: PING test 456 produces: 457 - text/plain 458 security: [] # No security 459 responses: 460 200: 461 description: Successful "PONG" reply 462 schema: 463 $ref: "#/definitions/Pong" 464 headers: 465 content-type: 466 type: string 467 x-example: text/plain; charset=utf-8 468 469 /ws: 470 get: 471 summary: Websocket handler 472 schemes: 473 - ws 474 - wss 475 responses: 476 200: 477 description: OK 478 401: 479 description: not authenticated 480 481 /info: 482 get: 483 summary: Fetches information about semaphore 484 description: you must be authenticated to use this 485 responses: 486 200: 487 description: ok 488 schema: 489 $ref: "#/definitions/InfoType" 490 491 /upgrade: 492 get: 493 summary: Check if new updates available and fetch /info 494 responses: 495 204: 496 description: no update 497 200: 498 description: ok 499 schema: 500 $ref: "#/definitions/InfoType" 501 post: 502 summary: Upgrade the server 503 responses: 504 200: 505 description: Server binary was replaced by new version, server has shut down. 506 507 # Authentication 508 /auth/login: 509 post: 510 tags: 511 - authentication 512 summary: Performs Login 513 description: | 514 Upon success you will be logged in 515 security: [] # No security 516 parameters: 517 - name: Login Body 518 in: body 519 required: true 520 schema: 521 $ref: '#/definitions/Login' 522 responses: 523 204: 524 description: You are logged in 525 400: 526 description: something in body is missing / is invalid 527 528 /auth/logout: 529 post: 530 tags: 531 - authentication 532 summary: Destroys current session 533 responses: 534 204: 535 description: Your session was successfully nuked 536 537 # User Tokens 538 /user/: 539 get: 540 tags: 541 - user 542 summary: Fetch logged in user 543 responses: 544 200: 545 description: User 546 schema: 547 $ref: "#/definitions/User" 548 549 /user/tokens: 550 get: 551 tags: 552 - authentication 553 - user 554 summary: Fetch API tokens for user 555 responses: 556 200: 557 description: API Tokens 558 schema: 559 type: array 560 items: 561 $ref: "#/definitions/APIToken" 562 post: 563 tags: 564 - authentication 565 - user 566 summary: Create an API token 567 responses: 568 201: 569 description: API Token 570 schema: 571 $ref: "#/definitions/APIToken" 572 573 /user/tokens/{api_token_id}: 574 parameters: 575 - name: api_token_id 576 in: path 577 type: string 578 required: true 579 x-example: "kwofd61g93-yuqvex8efmhjkgnbxlo8mp1tin6spyhu=" 580 delete: 581 tags: 582 - authentication 583 - user 584 summary: Expires API token 585 responses: 586 204: 587 description: Expired API Token 588 589 # User Profiles 590 /users: 591 get: 592 tags: 593 - user 594 summary: Fetches all users 595 responses: 596 200: 597 description: Users 598 schema: 599 type: array 600 items: 601 $ref: "#/definitions/User" 602 post: 603 tags: 604 - user 605 summary: Creates a user 606 consumes: 607 - application/json 608 parameters: 609 - name: User 610 in: body 611 required: true 612 schema: 613 $ref: "#/definitions/UserRequest" 614 responses: 615 400: 616 description: User creation failed 617 201: 618 description: User created 619 schema: 620 $ref: "#/definitions/User" 621 622 /users/{user_id}/: 623 parameters: 624 - $ref: "#/parameters/user_id" 625 get: 626 tags: 627 - user 628 summary: Fetches a user profile 629 responses: 630 200: 631 description: User profile 632 schema: 633 $ref: "#/definitions/User" 634 put: 635 tags: 636 - user 637 summary: Updates user details 638 consumes: 639 - application/json 640 parameters: 641 - name: User 642 in: body 643 required: true 644 schema: 645 $ref: "#/definitions/UserPutRequest" 646 responses: 647 204: 648 description: User Updated 649 650 delete: 651 tags: 652 - user 653 summary: Deletes user 654 responses: 655 204: 656 description: User deleted 657 658 /users/{user_id}/password: 659 parameters: 660 - $ref: "#/parameters/user_id" 661 post: 662 tags: 663 - user 664 summary: Updates user password 665 consumes: 666 - application/json 667 parameters: 668 - name: Password 669 in: body 670 required: true 671 schema: 672 type: object 673 properties: 674 password: 675 type: string 676 format: password 677 responses: 678 204: 679 description: Password updated 680 681 # Projects 682 /projects: 683 get: 684 tags: 685 - projects 686 summary: Get projects 687 responses: 688 200: 689 description: List of projects 690 schema: 691 type: array 692 items: 693 $ref: "#/definitions/Project" 694 post: 695 tags: 696 - projects 697 summary: Create a new project 698 consumes: 699 - application/json 700 parameters: 701 - name: Project 702 in: body 703 required: true 704 schema: 705 $ref: '#/definitions/ProjectRequest' 706 responses: 707 201: 708 description: Created project 709 710 /events: 711 get: 712 summary: Get Events related to Semaphore and projects you are part of 713 responses: 714 200: 715 description: Array of events in chronological order 716 schema: 717 type: array 718 items: 719 $ref: '#/definitions/Event' 720 /events/last: 721 get: 722 summary: Get last 200 Events related to Semaphore and projects you are part of 723 responses: 724 200: 725 description: Array of events in chronological order 726 schema: 727 type: array 728 items: 729 $ref: '#/definitions/Event' 730 731 /project/{project_id}/: 732 parameters: 733 - $ref: "#/parameters/project_id" 734 get: 735 tags: 736 - project 737 summary: Fetch project 738 responses: 739 200: 740 description: Project 741 schema: 742 $ref: "#/definitions/Project" 743 put: 744 tags: 745 - project 746 summary: Update project 747 parameters: 748 - name: Project 749 in: body 750 required: true 751 schema: 752 type: object 753 properties: 754 name: 755 type: string 756 responses: 757 204: 758 description: Project saved 759 delete: 760 tags: 761 - project 762 summary: Delete project 763 responses: 764 204: 765 description: Project deleted 766 767 /project/{project_id}/events: 768 parameters: 769 - $ref: '#/parameters/project_id' 770 get: 771 tags: 772 - project 773 summary: Get Events related to this project 774 responses: 775 200: 776 description: Array of events in chronological order 777 schema: 778 type: array 779 items: 780 $ref: '#/definitions/Event' 781 782 # User management 783 /project/{project_id}/users: 784 parameters: 785 - $ref: "#/parameters/project_id" 786 get: 787 tags: 788 - project 789 summary: Get users linked to project 790 parameters: 791 - name: sort 792 in: query 793 required: true 794 type: string 795 enum: [name, username, email, admin] 796 description: sorting name 797 x-example: email 798 - name: order 799 in: query 800 required: true 801 type: string 802 enum: [asc, desc] 803 description: ordering manner 804 x-example: desc 805 responses: 806 200: 807 description: Users 808 schema: 809 type: array 810 items: 811 $ref: "#/definitions/User" 812 post: 813 tags: 814 - project 815 summary: Link user to project 816 parameters: 817 - name: User 818 in: body 819 required: true 820 schema: 821 type: object 822 properties: 823 user_id: 824 type: integer 825 minimum: 2 826 admin: 827 type: boolean 828 responses: 829 204: 830 description: User added 831 /project/{project_id}/users/{user_id}: 832 parameters: 833 - $ref: "#/parameters/project_id" 834 - $ref: "#/parameters/user_id" 835 delete: 836 tags: 837 - project 838 summary: Removes user from project 839 responses: 840 204: 841 description: User removed 842 /project/{project_id}/users/{user_id}/admin: 843 parameters: 844 - $ref: "#/parameters/project_id" 845 - $ref: "#/parameters/user_id" 846 post: 847 tags: 848 - project 849 summary: Makes user admin 850 responses: 851 204: 852 description: User made administrator 853 delete: 854 tags: 855 - project 856 summary: Revoke admin privileges 857 responses: 858 204: 859 description: User admin privileges revoked 860 861 # project access keys 862 /project/{project_id}/keys: 863 parameters: 864 - $ref: "#/parameters/project_id" 865 get: 866 tags: 867 - project 868 summary: Get access keys linked to project 869 parameters: 870 # TODO - the space in this parameter name results in a dredd warning 871 - name: Key type 872 in: query 873 required: false 874 type: string 875 enum: [ssh, aws, gcloud, do] 876 description: Filter by key type 877 x-example: ssh 878 - name: sort 879 in: query 880 required: true 881 type: string 882 enum: [name, type] 883 description: sorting name 884 x-example: type 885 - name: order 886 in: query 887 required: true 888 type: string 889 enum: [asc, desc] 890 description: ordering manner 891 x-example: asc 892 responses: 893 200: 894 description: Access Keys 895 schema: 896 type: array 897 items: 898 $ref: "#/definitions/AccessKey" 899 post: 900 tags: 901 - project 902 summary: Add access key 903 parameters: 904 - name: Access Key 905 in: body 906 required: true 907 schema: 908 $ref: "#/definitions/AccessKeyRequest" 909 responses: 910 204: 911 description: Access Key created 912 400: 913 description: Bad type 914 /project/{project_id}/keys/{key_id}: 915 parameters: 916 - $ref: "#/parameters/project_id" 917 - $ref: "#/parameters/key_id" 918 put: 919 tags: 920 - project 921 summary: Updates access key 922 parameters: 923 - name: Access Key 924 in: body 925 required: true 926 schema: 927 $ref: "#/definitions/AccessKeyRequest" 928 responses: 929 204: 930 description: Key updated 931 400: 932 description: Bad type 933 delete: 934 tags: 935 - project 936 summary: Removes access key 937 responses: 938 204: 939 description: access key removed 940 941 # project repositories 942 /project/{project_id}/repositories: 943 parameters: 944 - $ref: "#/parameters/project_id" 945 get: 946 tags: 947 - project 948 summary: Get repositories 949 parameters: 950 - name: sort 951 in: query 952 required: true 953 type: string 954 enum: [name, git_url, ssh_key] 955 description: sorting name 956 - name: order 957 in: query 958 required: true 959 type: string 960 format: asc/desc 961 enum: [asc, desc] 962 description: ordering manner 963 responses: 964 200: 965 description: repositories 966 schema: 967 type: array 968 items: 969 $ref: "#/definitions/Repository" 970 post: 971 tags: 972 - project 973 summary: Add repository 974 parameters: 975 - name: Repository 976 in: body 977 required: true 978 schema: 979 $ref: "#/definitions/RepositoryRequest" 980 responses: 981 204: 982 description: Repository created 983 /project/{project_id}/repositories/{repository_id}: 984 parameters: 985 - $ref: "#/parameters/project_id" 986 - $ref: "#/parameters/repository_id" 987 delete: 988 tags: 989 - project 990 summary: Removes repository 991 responses: 992 204: 993 description: repository removed 994 995 # project inventory 996 /project/{project_id}/inventory: 997 parameters: 998 - $ref: "#/parameters/project_id" 999 get: 1000 tags: 1001 - project 1002 summary: Get inventory 1003 parameters: 1004 - name: sort 1005 in: query 1006 required: true 1007 type: string 1008 description: sorting name 1009 enum: [name, type] 1010 - name: order 1011 in: query 1012 required: true 1013 type: string 1014 description: ordering manner 1015 enum: [asc, desc] 1016 responses: 1017 200: 1018 description: inventory 1019 schema: 1020 type: array 1021 items: 1022 $ref: "#/definitions/Inventory" 1023 post: 1024 tags: 1025 - project 1026 summary: create inventory 1027 parameters: 1028 - name: Inventory 1029 in: body 1030 required: true 1031 schema: 1032 $ref: "#/definitions/InventoryRequest" 1033 responses: 1034 201: 1035 description: inventory created 1036 schema: 1037 $ref: "#/definitions/Inventory" 1038 /project/{project_id}/inventory/{inventory_id}: 1039 parameters: 1040 - $ref: "#/parameters/project_id" 1041 - $ref: "#/parameters/inventory_id" 1042 put: 1043 tags: 1044 - project 1045 summary: Updates inventory 1046 parameters: 1047 - name: Inventory 1048 in: body 1049 required: true 1050 schema: 1051 $ref: "#/definitions/InventoryRequest" 1052 responses: 1053 204: 1054 description: Inventory updated 1055 delete: 1056 tags: 1057 - project 1058 summary: Removes inventory 1059 responses: 1060 204: 1061 description: inventory removed 1062 1063 # project environment 1064 /project/{project_id}/environment: 1065 parameters: 1066 - $ref: "#/parameters/project_id" 1067 get: 1068 tags: 1069 - project 1070 summary: Get environment 1071 parameters: 1072 - name: sort 1073 in: query 1074 required: true 1075 type: string 1076 format: name 1077 description: sorting name 1078 x-example: 'db-deploy' 1079 - name: order 1080 in: query 1081 required: true 1082 type: string 1083 format: asc/desc 1084 description: ordering manner 1085 x-example: desc 1086 responses: 1087 200: 1088 description: environment 1089 schema: 1090 type: array 1091 items: 1092 $ref: "#/definitions/Environment" 1093 post: 1094 tags: 1095 - project 1096 summary: Add environment 1097 parameters: 1098 - name: environment 1099 in: body 1100 required: true 1101 schema: 1102 $ref: "#/definitions/EnvironmentRequest" 1103 responses: 1104 204: 1105 description: Environment created 1106 /project/{project_id}/environment/{environment_id}: 1107 parameters: 1108 - $ref: "#/parameters/project_id" 1109 - $ref: "#/parameters/environment_id" 1110 put: 1111 tags: 1112 - project 1113 summary: Update environment 1114 parameters: 1115 - name: environment 1116 in: body 1117 required: true 1118 schema: 1119 $ref: "#/definitions/EnvironmentRequest" 1120 responses: 1121 204: 1122 description: Environment Updated 1123 delete: 1124 tags: 1125 - project 1126 summary: Removes environment 1127 responses: 1128 204: 1129 description: environment removed 1130 1131 # project templates 1132 /project/{project_id}/templates: 1133 parameters: 1134 - $ref: "#/parameters/project_id" 1135 get: 1136 tags: 1137 - project 1138 summary: Get template 1139 parameters: 1140 - name: sort 1141 in: query 1142 required: true 1143 type: string 1144 description: sorting name 1145 enum: [alias, playbook, ssh_key, inventory, environment, repository] 1146 - name: order 1147 in: query 1148 required: true 1149 type: string 1150 description: ordering manner 1151 enum: [asc, desc] 1152 responses: 1153 200: 1154 description: template 1155 schema: 1156 type: array 1157 items: 1158 $ref: "#/definitions/Template" 1159 post: 1160 tags: 1161 - project 1162 summary: create template 1163 parameters: 1164 - name: template 1165 in: body 1166 required: true 1167 schema: 1168 $ref: "#/definitions/TemplateRequest" 1169 responses: 1170 201: 1171 description: template created 1172 schema: 1173 $ref: "#/definitions/Template" 1174 /project/{project_id}/templates/{template_id}: 1175 parameters: 1176 - $ref: "#/parameters/project_id" 1177 - $ref: "#/parameters/template_id" 1178 get: 1179 tags: 1180 - project 1181 summary: Get template 1182 responses: 1183 200: 1184 description: template object 1185 schema: 1186 $ref: "#/definitions/Template" 1187 put: 1188 tags: 1189 - project 1190 summary: Updates template 1191 parameters: 1192 - name: template 1193 in: body 1194 required: true 1195 schema: 1196 $ref: "#/definitions/TemplateRequest" 1197 responses: 1198 204: 1199 description: template updated 1200 delete: 1201 tags: 1202 - project 1203 summary: Removes template 1204 responses: 1205 204: 1206 description: template removed 1207 1208 # tasks 1209 /project/{project_id}/tasks: 1210 parameters: 1211 - $ref: "#/parameters/project_id" 1212 get: 1213 tags: 1214 - project 1215 summary: Get Tasks related to current project 1216 responses: 1217 200: 1218 description: Array of tasks in chronological order 1219 schema: 1220 type: array 1221 items: 1222 $ref: '#/definitions/Task' 1223 post: 1224 tags: 1225 - project 1226 summary: Starts a job 1227 parameters: 1228 - name: task 1229 in: body 1230 required: true 1231 schema: 1232 type: object 1233 properties: 1234 template_id: 1235 type: integer 1236 debug: 1237 type: boolean 1238 dry_run: 1239 type: boolean 1240 playbook: 1241 type: string 1242 environment: 1243 type: string 1244 responses: 1245 201: 1246 description: Task queued 1247 schema: 1248 $ref: "#/definitions/Task" 1249 /project/{project_id}/tasks/last: 1250 parameters: 1251 - $ref: "#/parameters/project_id" 1252 get: 1253 tags: 1254 - project 1255 summary: Get last 200 Tasks related to current project 1256 responses: 1257 200: 1258 description: Array of tasks in chronological order 1259 schema: 1260 type: array 1261 items: 1262 $ref: '#/definitions/Task' 1263 /project/{project_id}/tasks/{task_id}: 1264 parameters: 1265 - $ref: "#/parameters/project_id" 1266 - $ref: "#/parameters/task_id" 1267 get: 1268 tags: 1269 - project 1270 summary: Get a single task 1271 responses: 1272 200: 1273 description: Task 1274 schema: 1275 $ref: "#/definitions/Task" 1276 delete: 1277 tags: 1278 - project 1279 summary: Deletes task (including output) 1280 responses: 1281 204: 1282 description: task deleted 1283 /project/{project_id}/tasks/{task_id}/output: 1284 parameters: 1285 - $ref: '#/parameters/project_id' 1286 - $ref: '#/parameters/task_id' 1287 get: 1288 tags: 1289 - project 1290 summary: Get task output 1291 responses: 1292 200: 1293 description: output 1294 schema: 1295 type: array 1296 items: 1297 $ref: "#/definitions/TaskOutput" 1298