|
13 | 13 | url: https://confluence.biscrum.com/pages/viewpage.action?spaceKey=EDP&title=Welcome |
14 | 14 | servers: |
15 | 15 | - url: http://{baseurl}/v1 |
16 | | - variables: |
| 16 | + variables: |
17 | 17 | baseurl: |
18 | 18 | default: localhost:8080 |
19 | 19 | description: Default address for a Component Provisioner's backend REST API instance. |
@@ -336,6 +336,57 @@ paths: |
336 | 336 | application/json: |
337 | 337 | schema: |
338 | 338 | $ref: '#/components/schemas/RestErrorMessage' |
| 339 | + |
| 340 | + /project/components: |
| 341 | + get: |
| 342 | + operationId: getAllProjectComponents |
| 343 | + parameters: |
| 344 | + - name: page |
| 345 | + in: query |
| 346 | + description: Page number (from 0 until limit) |
| 347 | + required: false |
| 348 | + schema: |
| 349 | + type: integer |
| 350 | + default: 0 |
| 351 | + |
| 352 | + - name: size |
| 353 | + in: query |
| 354 | + description: Page size |
| 355 | + required: false |
| 356 | + schema: |
| 357 | + type: integer |
| 358 | + default: 20 |
| 359 | + responses: |
| 360 | + "200": |
| 361 | + content: |
| 362 | + application/json: |
| 363 | + schema: |
| 364 | + $ref: "#/components/schemas/ProjectComponentListResponse" |
| 365 | + description: A paginated list of all the provisioned project components |
| 366 | + "401": |
| 367 | + content: |
| 368 | + application/json: |
| 369 | + schema: |
| 370 | + $ref: "#/components/schemas/RestErrorMessage" |
| 371 | + description: Invalid client token on the request. |
| 372 | + "403": |
| 373 | + content: |
| 374 | + application/json: |
| 375 | + schema: |
| 376 | + $ref: "#/components/schemas/RestErrorMessage" |
| 377 | + description: Insufficient permissions for the client to access the resource. |
| 378 | + "500": |
| 379 | + content: |
| 380 | + application/json: |
| 381 | + schema: |
| 382 | + $ref: "#/components/schemas/RestErrorMessage" |
| 383 | + description: Server error. |
| 384 | + summary: Returns the information of the project's components in the Bitbucket |
| 385 | + repository. |
| 386 | + tags: |
| 387 | + - Project-components-with-provision-status |
| 388 | + x-accepts: |
| 389 | + - application/json |
339 | 390 | components: |
340 | 391 | securitySchemes: |
341 | 392 | bearerAuth: |
@@ -583,3 +634,108 @@ components: |
583 | 634 | type: array |
584 | 635 | items: |
585 | 636 | $ref: '#/components/schemas/ProjectComponentStatusParameter' |
| 637 | + ProjectComponentListItem: |
| 638 | + type: object |
| 639 | + example: |
| 640 | + projectKey: SOMEPROJECT |
| 641 | + componentId: any-component-id-from-backend |
| 642 | + caller: some-person@email.com |
| 643 | + catalogItemSlug: some_technology-name |
| 644 | + createdAt: 1707043200000 |
| 645 | + updatedAt: 1707043200000 |
| 646 | + properties: |
| 647 | + projectKey: |
| 648 | + description: The projectKey which the component is provisioned for. |
| 649 | + example: SOMEPROJECT |
| 650 | + type: string |
| 651 | + componentId: |
| 652 | + description: The componentId set by the user. |
| 653 | + example: any-component-id-from-backend |
| 654 | + minLength: 1 |
| 655 | + pattern: ^(?!\s*$).+ |
| 656 | + type: string |
| 657 | + caller: |
| 658 | + description: The email of who provisioned the component. |
| 659 | + example: some-person@email.com |
| 660 | + type: string |
| 661 | + catalogItemSlug: |
| 662 | + description: The provisioned catalog item slug. |
| 663 | + example: some_technology-name |
| 664 | + type: string |
| 665 | + createdAt: |
| 666 | + description: The timestamp of the provision action. |
| 667 | + example: 1707043200000 |
| 668 | + type: number |
| 669 | + updatedAt: |
| 670 | + description: The timestamp of the last change of the catalog item. |
| 671 | + example: 1707043200000 |
| 672 | + type: number |
| 673 | + Pagination: |
| 674 | + type: object |
| 675 | + example: |
| 676 | + page: 0 |
| 677 | + size: 20 |
| 678 | + totalElements: 117 |
| 679 | + totalPages: 6 |
| 680 | + next: "https://api.example.com/resources?page=1&size=20" |
| 681 | + previous: null |
| 682 | + properties: |
| 683 | + page: |
| 684 | + type: integer |
| 685 | + example: 0 |
| 686 | + description: Current page of the response. |
| 687 | + size: |
| 688 | + type: integer |
| 689 | + example: 20 |
| 690 | + description: Current page size of the response. |
| 691 | + totalElements: |
| 692 | + type: integer |
| 693 | + format: integer |
| 694 | + example: 117 |
| 695 | + description: Total number of elements. |
| 696 | + totalPages: |
| 697 | + type: integer |
| 698 | + example: 6 |
| 699 | + description: Total number of pages of this exact size. |
| 700 | + next: |
| 701 | + type: string |
| 702 | + format: uri |
| 703 | + nullable: true |
| 704 | + example: "https://api.example.com/resources?page=1&size=20" |
| 705 | + description: URL of the next page (or null if the current is the last one) |
| 706 | + previous: |
| 707 | + type: string |
| 708 | + format: uri |
| 709 | + nullable: true |
| 710 | + example: "https://api.example.com/resources?page=0&size=20" |
| 711 | + description: URL of the previous page (or null if the current is the first one) |
| 712 | + ProjectComponentListResponse: |
| 713 | + type: object |
| 714 | + example: |
| 715 | + data: |
| 716 | + - projectKey: SOMEPROJECT |
| 717 | + componentId: any-component-id-from-backend |
| 718 | + caller: some-person@email.com |
| 719 | + catalogItemSlug: some_technology-name |
| 720 | + createdAt: 1707043200000 |
| 721 | + updatedAt: 1707043200000 |
| 722 | + - projectKey: ANOTHERPROJECT |
| 723 | + componentId: another-component-id-from-backend |
| 724 | + caller: some-person2@email.com |
| 725 | + catalogItemSlug: another_technology-name |
| 726 | + createdAt: 1707043200001 |
| 727 | + updatedAt: 1707043200002 |
| 728 | + pagination: |
| 729 | + page: 0 |
| 730 | + size: 20 |
| 731 | + totalElements: 117 |
| 732 | + totalPages: 6 |
| 733 | + next: https://api.example.com/resources?page=1&size=20 |
| 734 | + previous: null |
| 735 | + properties: |
| 736 | + data: |
| 737 | + type: array |
| 738 | + items: |
| 739 | + $ref: '#/components/schemas/ProjectComponentListItem' |
| 740 | + pagination: |
| 741 | + $ref: '#/components/schemas/Pagination' |
0 commit comments