github.com/m3db/m3@v1.5.0/src/query/generated/assets/openapi/spec.yml (about) 1 openapi: 3.0.2 2 info: 3 title: M3DB 4 description: A distributed time series database using M3TSZ float64 compression. You can 5 find out more about M3DB at [https://m3db.io/docs](https://m3db.io/docs) 6 or on [GitHub](https://github.com/m3db/m3). 7 version: 1.0.0 8 contact: 9 name: M3BD Google Group 10 url: https://groups.google.com/forum/#!forum/m3db 11 license: 12 name: Apache License 2.0 13 url: https://github.com/m3db/m3/blob/master/LICENSE 14 tags: 15 - name: M3DB Namespace 16 description: Configuring M3DB namespaces 17 - name: M3DB Placement 18 description: Configuring M3DB placements 19 - name: M3DB Database 20 description: M3DB Database-wide functions 21 - name: M3Coordinator Placement 22 description: Configuring M3Coordinator placements 23 - name: M3Coordinator 24 description: Coordinates reads and writes 25 - name: M3Aggregator Placement 26 description: Configuring M3Aggregator placements 27 - name: M3Aggregator 28 description: Metrics aggregator and downsampler 29 servers: 30 - url: http://hostname:7201/api/v1 31 paths: 32 /services/m3db/namespace: 33 get: 34 description: Get all M3DB namespaces 35 tags: 36 - M3DB Namespace 37 operationId: m3DBNamespaceGet 38 responses: 39 "200": 40 description: "OK" 41 content: 42 application/json: 43 schema: 44 $ref: "#/components/schemas/NamespaceGetResponse" 45 "404": 46 description: "Not found" 47 content: 48 application/json: 49 schema: 50 $ref: "#/components/schemas/GenericError" 51 "500": 52 description: "Server error" 53 content: 54 application/json: 55 schema: 56 $ref: "#/components/schemas/GenericError" 57 post: 58 tags: 59 - M3DB Namespace 60 description: Add an M3DB namespace 61 operationId: m3DBNamespaceAdd 62 requestBody: 63 content: 64 application/json: 65 schema: 66 $ref: "#/components/schemas/NamespaceAddRequest" 67 responses: 68 "200": 69 description: "OK" 70 content: 71 application/json: 72 schema: 73 $ref: "#/components/schemas/NamespaceGetResponse" 74 "404": 75 description: "Not found" 76 content: 77 application/json: 78 schema: 79 $ref: "#/components/schemas/GenericError" 80 "500": 81 description: "Server error" 82 content: 83 application/json: 84 schema: 85 $ref: "#/components/schemas/GenericError" 86 put: 87 tags: 88 - M3DB Namespace 89 description: Update an M3DB namespace 90 operationId: m3DBNamespaceUpdate 91 requestBody: 92 content: 93 application/json: 94 schema: 95 $ref: "#/components/schemas/NamespaceUpdateRequest" 96 responses: 97 "200": 98 description: "OK" 99 content: 100 application/json: 101 schema: 102 $ref: "#/components/schemas/NamespaceGetResponse" 103 "404": 104 description: "Not found" 105 content: 106 application/json: 107 schema: 108 $ref: "#/components/schemas/GenericError" 109 "500": 110 description: "Server error" 111 content: 112 application/json: 113 schema: 114 $ref: "#/components/schemas/GenericError" 115 "/services/m3db/namespace/{namespaceID}": 116 delete: 117 tags: 118 - M3DB Namespace 119 description: Delete an M3DB namespace 120 operationId: m3DBNamespaceDelete 121 parameters: 122 - name: namespaceID 123 in: path 124 required: true 125 schema: 126 type: string 127 responses: 128 "200": 129 description: "OK" 130 content: 131 application/json: 132 schema: 133 $ref: "#/components/schemas/DeleteConfirmation" 134 "404": 135 description: "Not found" 136 content: 137 application/json: 138 schema: 139 $ref: "#/components/schemas/GenericError" 140 "500": 141 description: "Server error" 142 content: 143 application/json: 144 schema: 145 $ref: "#/components/schemas/GenericError" 146 /services/m3db/placement: 147 get: 148 tags: 149 - M3DB Placement 150 description: Get the M3DB placement 151 operationId: m3DBPlacementGet 152 responses: 153 "200": 154 description: "OK" 155 content: 156 application/json: 157 schema: 158 $ref: "#/components/schemas/PlacementGetResponse" 159 "500": 160 description: "Server error" 161 content: 162 application/json: 163 schema: 164 $ref: "#/components/schemas/GenericError" 165 post: 166 tags: 167 - M3DB Placement 168 description: Add an instance to the placement 169 operationId: m3DBPlacementAdd 170 requestBody: 171 $ref: "#/components/requestBodies/PlacementAddRequest" 172 responses: 173 "200": 174 description: "OK" 175 content: 176 application/json: 177 schema: 178 $ref: "#/components/schemas/PlacementGetResponse" 179 "404": 180 description: "Not found" 181 content: 182 application/json: 183 schema: 184 $ref: "#/components/schemas/GenericError" 185 "500": 186 description: "Server error" 187 content: 188 application/json: 189 schema: 190 $ref: "#/components/schemas/GenericError" 191 delete: 192 tags: 193 - M3DB Placement 194 description: Delete the M3DB placement 195 operationId: m3DBPlacementDeleteAll 196 responses: 197 "200": 198 description: "OK" 199 content: 200 application/json: 201 schema: 202 $ref: "#/components/schemas/DeleteConfirmation" 203 "500": 204 description: "Server error" 205 content: 206 application/json: 207 schema: 208 $ref: "#/components/schemas/GenericError" 209 /services/m3coordinator/placement: 210 get: 211 tags: 212 - M3Coordinator Placement 213 - M3Coordinator 214 description: Get the M3Coordinator placement 215 operationId: m3CoordPlacementGet 216 responses: 217 "200": 218 description: "OK" 219 content: 220 application/json: 221 schema: 222 $ref: "#/components/schemas/PlacementGetResponse" 223 "500": 224 description: "Server error" 225 content: 226 application/json: 227 schema: 228 $ref: "#/components/schemas/GenericError" 229 post: 230 tags: 231 - M3Coordinator Placement 232 - M3Coordinator 233 description: Add an instance to the placement 234 operationId: m3CoordPlacementAdd 235 requestBody: 236 $ref: "#/components/requestBodies/PlacementAddRequest" 237 responses: 238 "200": 239 description: "OK" 240 content: 241 application/json: 242 schema: 243 $ref: "#/components/schemas/PlacementGetResponse" 244 "404": 245 description: "Not found" 246 content: 247 application/json: 248 schema: 249 $ref: "#/components/schemas/GenericError" 250 "500": 251 description: "Server error" 252 content: 253 application/json: 254 schema: 255 $ref: "#/components/schemas/GenericError" 256 delete: 257 tags: 258 - M3Coordinator Placement 259 - M3Coordinator 260 description: Delete the M3Coordinator placement 261 operationId: m3CoordPlacementDeleteAll 262 responses: 263 "200": 264 description: "OK" 265 content: 266 application/json: 267 schema: 268 $ref: "#/components/schemas/DeleteConfirmation" 269 "500": 270 description: "Server error" 271 content: 272 application/json: 273 schema: 274 $ref: "#/components/schemas/GenericError" 275 /services/m3aggregator/placement: 276 get: 277 tags: 278 - M3Aggregator Placement 279 - M3Aggregator 280 description: Get the M3Agg placement 281 operationId: m3AggPlacementGet 282 responses: 283 "200": 284 description: "OK" 285 content: 286 application/json: 287 schema: 288 $ref: "#/components/schemas/PlacementGetResponse" 289 "500": 290 description: "Server error" 291 content: 292 application/json: 293 schema: 294 $ref: "#/components/schemas/GenericError" 295 post: 296 tags: 297 - M3Aggregator Placement 298 - M3Aggregator 299 description: Add an M3Agg instance to the placement 300 operationId: m3AggPlacementAdd 301 requestBody: 302 $ref: "#/components/requestBodies/PlacementAddRequest" 303 responses: 304 "200": 305 description: "OK" 306 content: 307 application/json: 308 schema: 309 $ref: "#/components/schemas/PlacementGetResponse" 310 "404": 311 description: "Not found" 312 content: 313 application/json: 314 schema: 315 $ref: "#/components/schemas/GenericError" 316 "500": 317 description: "Server error" 318 content: 319 application/json: 320 schema: 321 $ref: "#/components/schemas/GenericError" 322 delete: 323 tags: 324 - M3Aggregator Placement 325 - M3Aggregator 326 description: Delete the M3Agg placement 327 operationId: m3AggPlacementDeleteAll 328 responses: 329 "200": 330 description: "OK" 331 content: 332 application/json: 333 schema: 334 $ref: "#/components/schemas/DeleteConfirmation" 335 "500": 336 description: "Server error" 337 content: 338 application/json: 339 schema: 340 $ref: "#/components/schemas/GenericError" 341 /services/m3db/placement/init: 342 post: 343 tags: 344 - M3DB Placement 345 description: Initialize the M3DB placement 346 operationId: m3DBPlacementInit 347 requestBody: 348 $ref: "#/components/requestBodies/PlacementInitRequest" 349 responses: 350 "200": 351 description: "OK" 352 content: 353 application/json: 354 schema: 355 $ref: "#/components/schemas/PlacementGetResponse" 356 "404": 357 description: "Not found" 358 content: 359 application/json: 360 schema: 361 $ref: "#/components/schemas/GenericError" 362 "500": 363 description: "Server error" 364 content: 365 application/json: 366 schema: 367 $ref: "#/components/schemas/GenericError" 368 /services/m3db/placement/replace: 369 post: 370 tags: 371 - M3DB Placement 372 description: Replace an M3DB instance in the placement 373 operationId: m3DBPlacementReplace 374 requestBody: 375 $ref: "#/components/requestBodies/PlacementReplaceRequest" 376 responses: 377 "200": 378 description: "OK" 379 content: 380 application/json: 381 schema: 382 $ref: "#/components/schemas/PlacementGetResponse" 383 "404": 384 description: "Not found" 385 content: 386 application/json: 387 schema: 388 $ref: "#/components/schemas/GenericError" 389 "500": 390 description: "Server error" 391 content: 392 application/json: 393 schema: 394 $ref: "#/components/schemas/GenericError" 395 /services/m3coordinator/placement/init: 396 post: 397 tags: 398 - M3Coordinator Placement 399 - M3Coordinator 400 description: Initialize the M3Coordinator placement 401 operationId: m3CoordPlacementInit 402 requestBody: 403 content: 404 application/json: 405 schema: 406 $ref: "#/components/schemas/PlacementInitRequestM3Coordinator" 407 responses: 408 "200": 409 description: "OK" 410 content: 411 application/json: 412 schema: 413 $ref: "#/components/schemas/PlacementGetResponse" 414 "404": 415 description: "Not found" 416 content: 417 application/json: 418 schema: 419 $ref: "#/components/schemas/GenericError" 420 "500": 421 description: "Server error" 422 content: 423 application/json: 424 schema: 425 $ref: "#/components/schemas/GenericError" 426 /services/m3coordinator/placement/replace: 427 post: 428 tags: 429 - M3Coordinator Placement 430 - M3Coordinator 431 description: Replace an M3Coordinator 432 operationId: m3CoordPlacementReplace 433 requestBody: 434 $ref: "#/components/requestBodies/PlacementReplaceRequest" 435 responses: 436 "200": 437 description: "OK" 438 content: 439 application/json: 440 schema: 441 $ref: "#/components/schemas/PlacementGetResponse" 442 "404": 443 description: "Not found" 444 content: 445 application/json: 446 schema: 447 $ref: "#/components/schemas/GenericError" 448 "500": 449 description: "Server error" 450 content: 451 application/json: 452 schema: 453 $ref: "#/components/schemas/GenericError" 454 /services/m3aggregator/placement/init: 455 post: 456 tags: 457 - M3Aggregator Placement 458 - M3Aggregator 459 description: Initialize the M3Agg placement 460 operationId: m3AggPlacementInit 461 requestBody: 462 $ref: "#/components/requestBodies/PlacementInitRequest" 463 responses: 464 "200": 465 description: "OK" 466 content: 467 application/json: 468 schema: 469 $ref: "#/components/schemas/PlacementGetResponse" 470 "404": 471 description: "Not found" 472 content: 473 application/json: 474 schema: 475 $ref: "#/components/schemas/GenericError" 476 "500": 477 description: "Server error" 478 content: 479 application/json: 480 schema: 481 $ref: "#/components/schemas/GenericError" 482 /services/m3aggregator/placement/replace: 483 post: 484 tags: 485 - M3Aggregator Placement 486 - M3Aggregator 487 description: Replace an M3Aggregator 488 operationId: m3AggPlacementReplace 489 requestBody: 490 $ref: "#/components/requestBodies/PlacementReplaceRequest" 491 responses: 492 "200": 493 description: "OK" 494 content: 495 application/json: 496 schema: 497 $ref: "#/components/schemas/PlacementGetResponse" 498 "404": 499 description: "Not found" 500 content: 501 application/json: 502 schema: 503 $ref: "#/components/schemas/GenericError" 504 "500": 505 description: "Server error" 506 content: 507 application/json: 508 schema: 509 $ref: "#/components/schemas/GenericError" 510 "/services/m3db/placement/{instanceID}": 511 delete: 512 tags: 513 - M3DB Placement 514 description: Delete an M3DB instance from the placement 515 operationId: m3DBPlacementDelete 516 parameters: 517 - name: instanceID 518 in: path 519 required: true 520 schema: 521 type: string 522 responses: 523 "200": 524 description: "OK" 525 content: 526 application/json: 527 schema: 528 $ref: "#/components/schemas/PlacementGetResponse" 529 "404": 530 description: "Not found" 531 content: 532 application/json: 533 schema: 534 $ref: "#/components/schemas/GenericError" 535 "500": 536 description: "Server error" 537 content: 538 application/json: 539 schema: 540 $ref: "#/components/schemas/GenericError" 541 "/services/m3coordinator/placement/{instanceID}": 542 delete: 543 tags: 544 - M3Coordinator Placement 545 - M3Coordinator 546 description: Delete an M3Coordinator instance from the placement 547 operationId: m3CoordPlacementDelete 548 parameters: 549 - name: instanceID 550 in: path 551 required: true 552 schema: 553 type: string 554 responses: 555 "200": 556 description: "OK" 557 content: 558 application/json: 559 schema: 560 $ref: "#/components/schemas/PlacementGetResponse" 561 "404": 562 description: "Not found" 563 content: 564 application/json: 565 schema: 566 $ref: "#/components/schemas/GenericError" 567 "500": 568 description: "Server error" 569 content: 570 application/json: 571 schema: 572 $ref: "#/components/schemas/GenericError" 573 "/services/m3aggregator/placement/{instanceID}": 574 delete: 575 tags: 576 - M3Aggregator Placement 577 - M3Aggregator 578 description: Delete an M3Agg instance from the placement 579 operationId: m3AggPlacementDelete 580 parameters: 581 - name: instanceID 582 in: path 583 required: true 584 schema: 585 type: string 586 responses: 587 "200": 588 description: "OK" 589 content: 590 application/json: 591 schema: 592 $ref: "#/components/schemas/PlacementGetResponse" 593 "404": 594 description: "Not found" 595 content: 596 application/json: 597 schema: 598 $ref: "#/components/schemas/GenericError" 599 "500": 600 description: "Server error" 601 content: 602 application/json: 603 schema: 604 $ref: "#/components/schemas/GenericError" 605 /services/m3db/database/create: 606 post: 607 tags: 608 - M3DB Database 609 description: Configures M3DB with most options defaulted 610 operationId: m3DBDdatabaseCreate 611 requestBody: 612 content: 613 application/json: 614 schema: 615 $ref: "#/components/schemas/DatabaseCreateRequest" 616 responses: 617 "200": 618 description: "OK" 619 content: 620 application/json: 621 schema: 622 $ref: "#/components/schemas/DatabaseCreateResponse" 623 "404": 624 description: "Not found" 625 content: 626 application/json: 627 schema: 628 $ref: "#/components/schemas/GenericError" 629 "500": 630 description: "Server error" 631 content: 632 application/json: 633 schema: 634 $ref: "#/components/schemas/GenericError" 635 components: 636 requestBodies: 637 PlacementAddRequest: 638 content: 639 application/json: 640 schema: 641 $ref: "#/components/schemas/PlacementAddRequest" 642 PlacementInitRequest: 643 content: 644 application/json: 645 schema: 646 $ref: "#/components/schemas/PlacementInitRequest" 647 PlacementReplaceRequest: 648 content: 649 application/json: 650 schema: 651 $ref: "#/components/schemas/PlacementReplaceRequest" 652 schemas: 653 NamespaceAddRequest: 654 type: object 655 properties: 656 name: 657 type: string 658 options: 659 $ref: "#/components/schemas/NamespaceOptions" 660 NamespaceUpdateRequest: 661 type: object 662 properties: 663 name: 664 type: string 665 options: 666 type: object 667 properties: 668 retentionOptions: 669 type: object 670 properties: 671 retentionPeriodDuration: 672 type: string 673 runtimeOptions: 674 $ref: "#/components/schemas/NamespaceRuntimeOptions" 675 NamespaceOptions: 676 type: object 677 properties: 678 bootstrapEnabled: 679 type: boolean 680 flushEnabled: 681 type: boolean 682 writesToCommitLog: 683 type: boolean 684 cleanupEnabled: 685 type: boolean 686 repairEnabled: 687 type: boolean 688 retentionOptions: 689 $ref: "#/components/schemas/RetentionOptions" 690 snapshotEnabled: 691 type: boolean 692 indexOptions: 693 $ref: "#/components/schemas/IndexOptions" 694 runtimeOptions: 695 $ref: "#/components/schemas/NamespaceRuntimeOptions" 696 RetentionOptions: 697 type: object 698 properties: 699 retentionPeriodDuration: 700 type: string 701 blockSizeDuration: 702 type: string 703 bufferFutureDuration: 704 type: string 705 bufferPastDuration: 706 type: string 707 blockDataExpiry: 708 type: boolean 709 blockDataExpiryAfterNotAccessPeriodDuration: 710 type: string 711 IndexOptions: 712 type: object 713 properties: 714 enabled: 715 type: boolean 716 blockSizeDuration: 717 type: string 718 NamespaceRuntimeOptions: 719 type: object 720 properties: 721 flushIndexingPerCPUConcurrency: 722 type: number 723 format: double 724 writeIndexingPerCPUConcurrency: 725 type: number 726 format: double 727 NamespaceGetResponse: 728 type: object 729 properties: 730 registry: 731 $ref: "#/components/schemas/NamespaceRegistry" 732 NamespaceRegistry: 733 type: object 734 properties: 735 namespaces: 736 type: object 737 additionalProperties: 738 $ref: "#/components/schemas/NamespaceOptions" 739 DeleteConfirmation: 740 type: object 741 properties: 742 deleted: 743 type: boolean 744 PlacementGetResponse: 745 type: object 746 properties: 747 placement: 748 $ref: "#/components/schemas/Placement" 749 version: 750 type: integer 751 format: int32 752 Placement: 753 type: object 754 properties: 755 instances: 756 type: object 757 additionalProperties: 758 $ref: "#/components/schemas/Instance" 759 replicaFactor: 760 type: integer 761 numShards: 762 type: integer 763 isSharded: 764 type: boolean 765 cutoverTime: 766 type: integer 767 format: int64 768 isMirrored: 769 type: boolean 770 maxShardSetId: 771 type: integer 772 Instance: 773 type: object 774 properties: 775 id: 776 type: string 777 isolationGroup: 778 type: string 779 zone: 780 type: string 781 weight: 782 type: integer 783 endpoint: 784 type: string 785 shards: 786 type: array 787 items: 788 $ref: "#/components/schemas/Shard" 789 shardSetId: 790 type: integer 791 hostname: 792 type: string 793 port: 794 type: integer 795 InstanceRequest: 796 type: object 797 properties: 798 id: 799 type: string 800 isolationGroup: 801 type: string 802 zone: 803 type: string 804 weight: 805 type: integer 806 endpoint: 807 type: string 808 hostname: 809 type: string 810 port: 811 type: integer 812 Shard: 813 type: object 814 properties: 815 id: 816 type: integer 817 state: 818 $ref: "#/components/schemas/ShardState" 819 sourceId: 820 type: string 821 cutoverNanos: 822 type: integer 823 format: int64 824 cutoffNanos: 825 type: integer 826 format: int64 827 ShardState: 828 type: string 829 enum: 830 - INITIALIZING 831 - AVAILABLE 832 - LEAVING 833 PlacementAddRequest: 834 type: object 835 properties: 836 instances: 837 type: array 838 items: 839 $ref: "#/components/schemas/InstanceRequest" 840 force: 841 type: boolean 842 PlacementInitRequest: 843 type: object 844 properties: 845 instances: 846 type: array 847 items: 848 $ref: "#/components/schemas/InstanceRequest" 849 numShards: 850 type: integer 851 format: int32 852 replicationFactor: 853 type: integer 854 format: int32 855 PlacementReplaceRequest: 856 type: object 857 properties: 858 leavingInstanceIDs: 859 type: array 860 items: 861 type: string 862 candidates: 863 type: array 864 items: 865 $ref: "#/components/schemas/InstanceRequest" 866 force: 867 type: boolean 868 PlacementInitRequestM3Coordinator: 869 type: object 870 properties: 871 instances: 872 type: array 873 items: 874 $ref: "#/components/schemas/InstanceRequest" 875 GenericError: 876 type: object 877 properties: 878 status: 879 type: "string" 880 error: 881 type: string 882 DatabaseCreateRequest: 883 type: object 884 properties: 885 namespaceName: 886 type: string 887 type: 888 type: string 889 enum: 890 - local 891 - cluster 892 numShards: 893 type: integer 894 format: int32 895 replicationFactor: 896 type: integer 897 format: int32 898 retentionTime: 899 type: string 900 blockSize: 901 $ref: "#/components/schemas/BlockSize" 902 hosts: 903 type: array 904 items: 905 $ref: "#/components/schemas/Host" 906 BlockSize: 907 type: object 908 properties: 909 time: 910 type: string 911 expectedSeriesDatapointsPerHour: 912 type: integer 913 format: int64 914 Host: 915 type: object 916 properties: 917 id: 918 type: string 919 address: 920 type: string 921 port: 922 type: integer 923 isolationGroup: 924 type: string 925 zone: 926 type: string 927 weight: 928 type: integer 929 expectedSeriesDatapointsPerHour: 930 type: integer 931 format: int64 932 DatabaseCreateResponse: 933 type: object 934 properties: 935 namespace: 936 $ref: "#/components/schemas/NamespaceGetResponse" 937 placement: 938 $ref: "#/components/schemas/PlacementGetResponse"