|
1595 | 1595 | "format" : "date-time",
|
1596 | 1596 | "x-is-datetime" : true
|
1597 | 1597 | },
|
| 1598 | + "niCategory" : { |
| 1599 | + "$ref" : "#/components/schemas/NICategoryLetter" |
| 1600 | + }, |
| 1601 | + "niCategories" : { |
| 1602 | + "type" : "array", |
| 1603 | + "description" : "The employee's NI categories", |
| 1604 | + "items" : { |
| 1605 | + "$ref" : "#/components/schemas/NICategory" |
| 1606 | + } |
| 1607 | + }, |
1598 | 1608 | "nationalInsuranceNumber" : {
|
1599 | 1609 | "type" : "string",
|
1600 | 1610 | "description" : "National insurance number of the employee",
|
|
2262 | 2272 | };
|
2263 | 2273 | defs["Employment"] = {
|
2264 | 2274 | "title" : "",
|
2265 |
| - "required" : [ "EmployeeNumber", "NICategory", "PayrollCalendarID", "StartDate" ], |
| 2275 | + "required" : [ "EmployeeNumber", "NICategories", "PayrollCalendarID", "StartDate" ], |
2266 | 2276 | "type" : "object",
|
2267 | 2277 | "properties" : {
|
2268 | 2278 | "payrollCalendarID" : {
|
|
2282 | 2292 | "example" : "7"
|
2283 | 2293 | },
|
2284 | 2294 | "niCategory" : {
|
2285 |
| - "type" : "string", |
2286 |
| - "description" : "The NI Category of the employee", |
2287 |
| - "example" : "A", |
2288 |
| - "enum" : [ "A", "B", "C", "F", "H", "I", "J", "L", "M", "S", "V", "X", "Z" ] |
| 2295 | + "$ref" : "#/components/schemas/NICategoryLetter" |
| 2296 | + }, |
| 2297 | + "niCategories" : { |
| 2298 | + "type" : "array", |
| 2299 | + "description" : "The employee's NI categories", |
| 2300 | + "items" : { |
| 2301 | + "$ref" : "#/components/schemas/NICategory" |
| 2302 | + } |
2289 | 2303 | }
|
2290 | 2304 | },
|
2291 | 2305 | "description" : ""
|
|
2502 | 2516 | }
|
2503 | 2517 | },
|
2504 | 2518 | "description" : ""
|
| 2519 | +}; |
| 2520 | + defs["NICategory"] = { |
| 2521 | + "title" : "", |
| 2522 | + "required" : [ "niCategory", "workplacePostcode" ], |
| 2523 | + "type" : "object", |
| 2524 | + "properties" : { |
| 2525 | + "startDate" : { |
| 2526 | + "type" : "string", |
| 2527 | + "description" : "The start date of the NI category (YYYY-MM-DD)", |
| 2528 | + "format" : "date", |
| 2529 | + "example" : "2024-12-02", |
| 2530 | + "x-is-date" : true |
| 2531 | + }, |
| 2532 | + "niCategory" : { |
| 2533 | + "$ref" : "#/components/schemas/NICategoryLetter" |
| 2534 | + }, |
| 2535 | + "niCategoryID" : { |
| 2536 | + "type" : "number", |
| 2537 | + "description" : "Xero unique identifier for the NI category", |
| 2538 | + "example" : 15 |
| 2539 | + }, |
| 2540 | + "dateFirstEmployedAsCivilian" : { |
| 2541 | + "type" : "string", |
| 2542 | + "description" : "The date in which the employee was first employed as a civilian (YYYY-MM-DD)", |
| 2543 | + "format" : "date", |
| 2544 | + "example" : "2024-12-02", |
| 2545 | + "x-is-date" : true |
| 2546 | + }, |
| 2547 | + "workplacePostcode" : { |
| 2548 | + "type" : "string", |
| 2549 | + "description" : "The workplace postcode", |
| 2550 | + "example" : "SW1A 1AA" |
| 2551 | + } |
| 2552 | + }, |
| 2553 | + "description" : "", |
| 2554 | + "oneOf" : [ { |
| 2555 | + "$ref" : "#/components/schemas/NICategory_oneOf" |
| 2556 | + }, { |
| 2557 | + "$ref" : "#/components/schemas/NICategory_oneOf_1" |
| 2558 | + } ] |
| 2559 | +}; |
| 2560 | + defs["NICategoryLetter"] = { |
| 2561 | + "title" : "", |
| 2562 | + "type" : "string", |
| 2563 | + "description" : "The employee's NI Category letter.", |
| 2564 | + "example" : "I", |
| 2565 | + "enum" : [ "A", "B", "C", "D", "E", "F", "H", "I", "J", "K", "L", "M", "N", "S", "V", "X", "Z" ] |
| 2566 | +}; |
| 2567 | + defs["NICategory_oneOf"] = { |
| 2568 | + "title" : "", |
| 2569 | + "required" : [ "workplacePostcode" ], |
| 2570 | + "properties" : { |
| 2571 | + "niCategory" : { |
| 2572 | + "type" : "string", |
| 2573 | + "enum" : [ "F", "I", "L", "S", "N", "E", "D", "K" ] |
| 2574 | + } |
| 2575 | + }, |
| 2576 | + "description" : "" |
| 2577 | +}; |
| 2578 | + defs["NICategory_oneOf_1"] = { |
| 2579 | + "title" : "", |
| 2580 | + "required" : [ "dateFirstEmployedAsCivilian" ], |
| 2581 | + "properties" : { |
| 2582 | + "niCategory" : { |
| 2583 | + "type" : "string", |
| 2584 | + "enum" : [ "V" ] |
| 2585 | + } |
| 2586 | + }, |
| 2587 | + "description" : "" |
2505 | 2588 | };
|
2506 | 2589 | defs["Pagination"] = {
|
2507 | 2590 | "title" : "",
|
|
3518 | 3601 | <nav id="scrollingNav">
|
3519 | 3602 | <ul class="sidenav nav nav-list">
|
3520 | 3603 | <li class="nav-header" data-group="PayrollUk"><strong>SDK: </strong><span id='sdk-name'></span></li>
|
3521 |
| - <li class="nav-header" data-group="PayrollUk"><strong>VSN: </strong>10.1.0</li> |
| 3604 | + <li class="nav-header" data-group="PayrollUk"><strong>VSN: </strong>11.0.0</li> |
3522 | 3605 | <li class="nav-header" data-group="PayrollUk"><a href="#api-PayrollUk">Methods</a></li>
|
3523 | 3606 | <li data-group="PayrollUk" data-name="approveTimesheet" class="">
|
3524 | 3607 | <a href="#api-PayrollUk-approveTimesheet">approveTimesheet</a>
|
@@ -5715,6 +5798,8 @@ <h3>Usage and SDK Samples</h3>
|
5715 | 5798 | startDate: startDate
|
5716 | 5799 | };
|
5717 | 5800 |
|
| 5801 | +const niCategories: NICategories = { |
| 5802 | + |
5718 | 5803 | try {
|
5719 | 5804 | const response = await xero.accountingApi.createEmployment(xeroTenantId, employeeID, employment, idempotencyKey);
|
5720 | 5805 | console.log(response.body || response.response.statusCode)
|
@@ -5846,7 +5931,7 @@ <h2>Parameters</h2>
|
5846 | 5931 | "schema" : {
|
5847 | 5932 | "$ref" : "#/components/schemas/Employment"
|
5848 | 5933 | },
|
5849 |
| - "example" : "{ \"PayrollCalendarID\": \"216d80e6-af55-47b1-b718-9457c3f5d2fe\", \"StartDate\": \"2020-04-01\", \"EmployeeNumber\": \"123ABC\", \"NICategory\": \"A\" }" |
| 5934 | + "example" : "{ \"PayrollCalendarID\": \"216d80e6-af55-47b1-b718-9457c3f5d2fe\", \"StartDate\": \"2020-04-01\", \"NICategories\": [ { \"NICategory\": \"A\", \"StartDate\": \"2020-05-01\" } ], \"EmployeeNumber\": \"123ABC\" }" |
5850 | 5935 | }
|
5851 | 5936 | },
|
5852 | 5937 | "required" : true
|
|
0 commit comments