|
1 | 1 | openapi: 3.0.0
|
2 | 2 | info:
|
3 |
| - version: "2.22.4" |
| 3 | + version: "2.23.0" |
4 | 4 | title: Xero Projects API
|
5 | 5 | description: This is the Xero Projects API
|
6 | 6 | termsOfService: "https://developer.xero.com/xero-developer-platform-terms-conditions/"
|
@@ -551,40 +551,42 @@ paths:
|
551 | 551 | }
|
552 | 552 | ]
|
553 | 553 | }'
|
554 |
| - # post: |
555 |
| - # security: |
556 |
| - # - OAuth2: [projects] |
557 |
| - # tags: |
558 |
| - # - Project |
559 |
| - # summary: Allows you to create a task |
560 |
| - # operationId: createTask |
561 |
| - # description: Allows you to create a specific task |
562 |
| - # parameters: |
563 |
| - # - name: projectId |
564 |
| - # in: path |
565 |
| - # required: true |
566 |
| - # description: You can create a task on a specified projectId |
567 |
| - # schema: |
568 |
| - # type: string |
569 |
| - # format: uuid |
570 |
| - # requestBody: |
571 |
| - # required: true |
572 |
| - # description: The task object you are creating |
573 |
| - # content: |
574 |
| - # application/json: |
575 |
| - # schema: |
576 |
| - # $ref: '#/components/schemas/TaskCreateOrUpdate' |
577 |
| - # example: |
578 |
| - # '{ |
579 |
| - # "status": "INPROGRESS" |
580 |
| - # }' |
581 |
| - # responses: |
582 |
| - # '200': |
583 |
| - # description: OK/success, returns a list of tasks created |
584 |
| - # content: |
585 |
| - # application/json: |
586 |
| - # schema: |
587 |
| - # $ref: '#/components/schemas/Tasks' |
| 554 | + '400': |
| 555 | + $ref: '#/components/responses/400Error' |
| 556 | + post: |
| 557 | + security: |
| 558 | + - OAuth2: [projects] |
| 559 | + tags: |
| 560 | + - Project |
| 561 | + summary: Allows you to create a task |
| 562 | + operationId: createTask |
| 563 | + description: Allows you to create a specific task |
| 564 | + parameters: |
| 565 | + - name: projectId |
| 566 | + x-snake: project_id |
| 567 | + in: path |
| 568 | + required: true |
| 569 | + description: You can create a task on a specified projectId |
| 570 | + schema: |
| 571 | + type: string |
| 572 | + format: uuid |
| 573 | + requestBody: |
| 574 | + required: true |
| 575 | + description: The task object you are creating |
| 576 | + content: |
| 577 | + application/json: |
| 578 | + schema: |
| 579 | + $ref: '#/components/schemas/TaskCreateOrUpdate' |
| 580 | + example: |
| 581 | + '{ |
| 582 | + "status": "INPROGRESS" |
| 583 | + }' |
| 584 | + responses: |
| 585 | + '201': |
| 586 | + description: OK/Success - return response 201 no content |
| 587 | + x-isEmpty: true |
| 588 | + '400': |
| 589 | + $ref: '#/components/responses/400Error' |
588 | 590 | /Projects/{projectId}/Tasks/{taskId}:
|
589 | 591 | parameters:
|
590 | 592 | - $ref: '#/components/parameters/requiredHeader'
|
@@ -649,71 +651,78 @@ paths:
|
649 | 651 | "value": 0
|
650 | 652 | }
|
651 | 653 | }'
|
652 |
| - # put: |
653 |
| - # security: |
654 |
| - # - OAuth2: [projects] |
655 |
| - # tags: |
656 |
| - # - Project |
657 |
| - # summary: Allows you to update a task |
658 |
| - # operationId: updateTask |
659 |
| - # description: Allows you to update a specific task |
660 |
| - # parameters: |
661 |
| - # - name: projectId |
662 |
| - # in: path |
663 |
| - # required: true |
664 |
| - # description: You can specify an individual project by appending the projectId to the endpoint |
665 |
| - # schema: |
666 |
| - # type: string |
667 |
| - # format: uuid |
668 |
| - # - name: taskId |
669 |
| - # in: path |
670 |
| - # required: true |
671 |
| - # description: You can specify an individual task by appending the id to the endpoint |
672 |
| - # schema: |
673 |
| - # type: string |
674 |
| - # format: uuid |
675 |
| - # requestBody: |
676 |
| - # required: true |
677 |
| - # description: The task object you are updating |
678 |
| - # content: |
679 |
| - # application/json: |
680 |
| - # schema: |
681 |
| - # $ref: '#/components/schemas/TaskCreateOrUpdate' |
682 |
| - # example: '' |
683 |
| - # responses: |
684 |
| - # '200': |
685 |
| - # description: OK/success, returns a list of tasks updated |
686 |
| - # content: |
687 |
| - # application/json: |
688 |
| - # schema: |
689 |
| - # $ref: '#/components/schemas/Tasks' |
690 |
| - # delete: |
691 |
| - # security: |
692 |
| - # - OAuth2: [projects] |
693 |
| - # tags: |
694 |
| - # - Project |
695 |
| - # summary: Allows you to delete a task |
696 |
| - # operationId: deleteTask |
697 |
| - # description: Allows you to delete a specific task |
698 |
| - # parameters: |
699 |
| - # - name: projectId |
700 |
| - # in: path |
701 |
| - # required: true |
702 |
| - # description: You can specify an individual project by appending the projectId to the endpoint |
703 |
| - # schema: |
704 |
| - # type: string |
705 |
| - # format: uuid |
706 |
| - # - name: taskId |
707 |
| - # in: path |
708 |
| - # required: true |
709 |
| - # description: You can specify an individual task by appending the id to the endpoint |
710 |
| - # schema: |
711 |
| - # type: string |
712 |
| - # format: uuid |
713 |
| - # responses: |
714 |
| - # '204': |
715 |
| - # description: Success - return response 204 no content |
716 |
| - # x-isEmpty: true |
| 654 | + '400': |
| 655 | + $ref: '#/components/responses/400Error' |
| 656 | + put: |
| 657 | + security: |
| 658 | + - OAuth2: [projects] |
| 659 | + tags: |
| 660 | + - Project |
| 661 | + summary: Allows you to update a task |
| 662 | + operationId: updateTask |
| 663 | + description: Allows you to update a specific task |
| 664 | + parameters: |
| 665 | + - name: projectId |
| 666 | + x-snake: project_id |
| 667 | + in: path |
| 668 | + required: true |
| 669 | + description: You can specify an individual project by appending the projectId to the endpoint |
| 670 | + schema: |
| 671 | + type: string |
| 672 | + format: uuid |
| 673 | + - name: taskId |
| 674 | + x-snake: task_id |
| 675 | + in: path |
| 676 | + required: true |
| 677 | + description: You can specify an individual task by appending the id to the endpoint |
| 678 | + schema: |
| 679 | + type: string |
| 680 | + format: uuid |
| 681 | + requestBody: |
| 682 | + required: true |
| 683 | + description: The task object you are updating |
| 684 | + content: |
| 685 | + application/json: |
| 686 | + schema: |
| 687 | + $ref: '#/components/schemas/TaskCreateOrUpdate' |
| 688 | + example: '' |
| 689 | + responses: |
| 690 | + '204': |
| 691 | + description: OK/Success - return response 204 no content |
| 692 | + x-isEmpty: true |
| 693 | + '400': |
| 694 | + $ref: '#/components/responses/400Error' |
| 695 | + delete: |
| 696 | + security: |
| 697 | + - OAuth2: [projects] |
| 698 | + tags: |
| 699 | + - Project |
| 700 | + summary: Allows you to delete a task |
| 701 | + operationId: deleteTask |
| 702 | + description: Allows you to delete a specific task |
| 703 | + parameters: |
| 704 | + - name: projectId |
| 705 | + x-snake: project_id |
| 706 | + in: path |
| 707 | + required: true |
| 708 | + description: You can specify an individual project by appending the projectId to the endpoint |
| 709 | + schema: |
| 710 | + type: string |
| 711 | + format: uuid |
| 712 | + - name: taskId |
| 713 | + x-snake: task_id |
| 714 | + in: path |
| 715 | + required: true |
| 716 | + description: You can specify an individual task by appending the id to the endpoint |
| 717 | + schema: |
| 718 | + type: string |
| 719 | + format: uuid |
| 720 | + responses: |
| 721 | + '204': |
| 722 | + description: Success - return response 204 no content |
| 723 | + x-isEmpty: true |
| 724 | + '400': |
| 725 | + $ref: '#/components/responses/400Error' |
717 | 726 | /Projects/{projectId}/Time:
|
718 | 727 | parameters:
|
719 | 728 | - $ref: '#/components/parameters/requiredHeader'
|
@@ -841,6 +850,8 @@ paths:
|
841 | 850 | }
|
842 | 851 | ]
|
843 | 852 | }'
|
| 853 | + '400': |
| 854 | + $ref: '#/components/responses/400Error' |
844 | 855 | post:
|
845 | 856 | security:
|
846 | 857 | - OAuth2: [projects]
|
@@ -890,6 +901,8 @@ paths:
|
890 | 901 | "description": "My description",
|
891 | 902 | "status": "ACTIVE"
|
892 | 903 | }'
|
| 904 | + '400': |
| 905 | + $ref: '#/components/responses/400Error' |
893 | 906 | /Projects/{projectId}/Time/{timeEntryId}:
|
894 | 907 | parameters:
|
895 | 908 | - $ref: '#/components/parameters/requiredHeader'
|
@@ -936,6 +949,8 @@ paths:
|
936 | 949 | "description": "My description",
|
937 | 950 | "status": "ACTIVE"
|
938 | 951 | }'
|
| 952 | + '400': |
| 953 | + $ref: '#/components/responses/400Error' |
939 | 954 | put:
|
940 | 955 | security:
|
941 | 956 | - OAuth2: [projects]
|
@@ -979,6 +994,8 @@ paths:
|
979 | 994 | '204':
|
980 | 995 | description: Success - return response 204 no content
|
981 | 996 | x-isEmpty: true
|
| 997 | + '400': |
| 998 | + $ref: '#/components/responses/400Error' |
982 | 999 | delete:
|
983 | 1000 | security:
|
984 | 1001 | - OAuth2: [projects]
|
@@ -1008,6 +1025,8 @@ paths:
|
1008 | 1025 | '204':
|
1009 | 1026 | description: Success - return response 204 no content
|
1010 | 1027 | x-isEmpty: true
|
| 1028 | + '400': |
| 1029 | + $ref: '#/components/responses/400Error' |
1011 | 1030 | components:
|
1012 | 1031 | securitySchemes:
|
1013 | 1032 | OAuth2:
|
@@ -1434,36 +1453,30 @@ components:
|
1434 | 1453 | $ref: '#/components/schemas/ChargeType'
|
1435 | 1454 | type: string
|
1436 | 1455 | estimateMinutes:
|
1437 |
| - type: number |
1438 |
| - format: double |
| 1456 | + type: integer |
1439 | 1457 | description: An estimated time to perform the task
|
1440 | 1458 | projectId:
|
1441 | 1459 | type: string
|
1442 | 1460 | format: uuid
|
1443 | 1461 | example: '00000000-0000-0000-000-000000000000'
|
1444 | 1462 | description: Identifier of the project task belongs to.
|
1445 | 1463 | totalMinutes:
|
1446 |
| - type: number |
1447 |
| - format: double |
| 1464 | + type: integer |
1448 | 1465 | description: Total minutes which have been logged against the task. Logged by assigning a time entry to a task
|
1449 | 1466 | totalAmount:
|
1450 | 1467 | $ref: '#/components/schemas/Amount'
|
1451 | 1468 | type: number
|
1452 | 1469 | minutesInvoiced:
|
1453 |
| - type: number |
1454 |
| - format: double |
| 1470 | + type: integer |
1455 | 1471 | description: Minutes on this task which have been invoiced.
|
1456 | 1472 | minutesToBeInvoiced:
|
1457 |
| - type: number |
1458 |
| - format: double |
| 1473 | + type: integer |
1459 | 1474 | description: Minutes on this task which have not been invoiced.
|
1460 | 1475 | fixedMinutes:
|
1461 |
| - type: number |
1462 |
| - format: double |
| 1476 | + type: integer |
1463 | 1477 | description: Minutes logged against this task if its charge type is `FIXED`.
|
1464 | 1478 | nonChargeableMinutes:
|
1465 |
| - type: number |
1466 |
| - format: double |
| 1479 | + type: integer |
1467 | 1480 | description: Minutes logged against this task if its charge type is `NON_CHARGEABLE`.
|
1468 | 1481 | amountToBeInvoiced:
|
1469 | 1482 | $ref: '#/components/schemas/Amount'
|
@@ -1496,12 +1509,13 @@ components:
|
1496 | 1509 | maximum: 100
|
1497 | 1510 | rate:
|
1498 | 1511 | $ref: '#/components/schemas/Amount'
|
| 1512 | + type: number |
1499 | 1513 | chargeType:
|
1500 | 1514 | $ref: '#/components/schemas/ChargeType'
|
1501 | 1515 | type: string
|
1502 | 1516 | estimateMinutes:
|
1503 | 1517 | type: integer
|
1504 |
| - description: "Estimated time to perform the task. EstimateMinutes has to be greater than 0 if provided." |
| 1518 | + description: An estimated time to perform the task |
1505 | 1519 | required:
|
1506 | 1520 | - name
|
1507 | 1521 | - rate
|
|
0 commit comments