@dsptch-work/api-client 0.40.0 → 0.42.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +191 -0
- package/dist/gen/index.d.ts +1 -1
- package/dist/gen/sdk.gen.d.ts +370 -28
- package/dist/gen/sdk.gen.js +503 -27
- package/dist/gen/types.gen.d.ts +1467 -87
- package/dist/gen/zod.gen.d.ts +1442 -202
- package/dist/gen/zod.gen.js +524 -46
- package/package.json +1 -1
package/dist/gen/sdk.gen.js
CHANGED
|
@@ -1314,6 +1314,29 @@ export class AssetsItems {
|
|
|
1314
1314
|
}
|
|
1315
1315
|
});
|
|
1316
1316
|
}
|
|
1317
|
+
/**
|
|
1318
|
+
* Delete form assignment
|
|
1319
|
+
*
|
|
1320
|
+
* Ends the open incomplete permanent copy of this nested
|
|
1321
|
+
* form-completion task, the same mutation as the web unassign
|
|
1322
|
+
* control. Recurrence stays on PATCH. A copy that is not an
|
|
1323
|
+
* incomplete permanent copy is refused with
|
|
1324
|
+
* `not_incomplete_permanent_copy`. A missing, misnested, or
|
|
1325
|
+
* out-of-scope id reads as not found. Returns `204`.
|
|
1326
|
+
*
|
|
1327
|
+
*
|
|
1328
|
+
* **Required scope:**
|
|
1329
|
+
*
|
|
1330
|
+
* `assets.items.form_assignment_tasks:delete`
|
|
1331
|
+
*
|
|
1332
|
+
*/
|
|
1333
|
+
static deleteFormAssignmentTask(options) {
|
|
1334
|
+
return (options.client ?? client).delete({
|
|
1335
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
1336
|
+
url: '/api/v1/assets/items/{item_id}/form_assignment_tasks/{id}',
|
|
1337
|
+
...options
|
|
1338
|
+
});
|
|
1339
|
+
}
|
|
1317
1340
|
/**
|
|
1318
1341
|
* Show form assignment
|
|
1319
1342
|
*
|
|
@@ -2119,6 +2142,11 @@ export class Billing {
|
|
|
2119
2142
|
/**
|
|
2120
2143
|
* List PWA user counts
|
|
2121
2144
|
*
|
|
2145
|
+
* Lists each month's PWA head count per billable unit: a project, or a
|
|
2146
|
+
* job outside any project. Rows run newest month first, then projects by
|
|
2147
|
+
* name, then jobs outside any project by name.
|
|
2148
|
+
*
|
|
2149
|
+
*
|
|
2122
2150
|
* **Required scope:**
|
|
2123
2151
|
*
|
|
2124
2152
|
* `billing.pwa_user_counts_by_project_by_months:read`
|
|
@@ -3669,6 +3697,23 @@ export class Forms {
|
|
|
3669
3697
|
* SurveyJS required-answer rules, visibility, defaults, or expressions.
|
|
3670
3698
|
* Returns the same representation as show.
|
|
3671
3699
|
*
|
|
3700
|
+
* File and signature answers take signed IDs, never file contents.
|
|
3701
|
+
* Upload each file first: call POST /api/v1/direct_uploads with
|
|
3702
|
+
* resource form_submissions, PUT the bytes to the returned
|
|
3703
|
+
* direct_upload.url with its headers, then send the returned
|
|
3704
|
+
* signed_id here within a week.
|
|
3705
|
+
*
|
|
3706
|
+
* - A file answer is an array holding one signed ID per file. Each
|
|
3707
|
+
* file is attached to the submission, and the response returns a
|
|
3708
|
+
* download URL in its place. An image file may hold at most 10 MiB.
|
|
3709
|
+
* - A signature answer is one signed ID, and its image is stored in
|
|
3710
|
+
* the answer as a data URL. It must be a PNG or JPEG image, declared
|
|
3711
|
+
* as image/png or image/jpeg to match its bytes or as
|
|
3712
|
+
* application/octet-stream, hold at most 256 KiB, and span at most
|
|
3713
|
+
* 2,000 pixels on either side. A submission's signature answers may
|
|
3714
|
+
* hold at most 2 MiB together, and an upload counts once for each
|
|
3715
|
+
* answer naming it.
|
|
3716
|
+
*
|
|
3672
3717
|
*
|
|
3673
3718
|
* **Required scope:**
|
|
3674
3719
|
*
|
|
@@ -3686,6 +3731,27 @@ export class Forms {
|
|
|
3686
3731
|
}
|
|
3687
3732
|
});
|
|
3688
3733
|
}
|
|
3734
|
+
/**
|
|
3735
|
+
* Delete form submission
|
|
3736
|
+
*
|
|
3737
|
+
* Deletes a submission that is not used as competency evidence.
|
|
3738
|
+
* Competency-evidence restriction is refused with `422`
|
|
3739
|
+
* `destroy_restricted`. Form-assignment rows that pointed at the
|
|
3740
|
+
* submission are nullified. Attachments are kept. Returns `204`.
|
|
3741
|
+
*
|
|
3742
|
+
*
|
|
3743
|
+
* **Required scope:**
|
|
3744
|
+
*
|
|
3745
|
+
* `form_submissions:delete`
|
|
3746
|
+
*
|
|
3747
|
+
*/
|
|
3748
|
+
static deleteFormSubmission(options) {
|
|
3749
|
+
return (options.client ?? client).delete({
|
|
3750
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
3751
|
+
url: '/api/v1/form_submissions/{id}',
|
|
3752
|
+
...options
|
|
3753
|
+
});
|
|
3754
|
+
}
|
|
3689
3755
|
/**
|
|
3690
3756
|
* Show form submission
|
|
3691
3757
|
*
|
|
@@ -3701,6 +3767,31 @@ export class Forms {
|
|
|
3701
3767
|
...options
|
|
3702
3768
|
});
|
|
3703
3769
|
}
|
|
3770
|
+
/**
|
|
3771
|
+
* Update form submission
|
|
3772
|
+
*
|
|
3773
|
+
* Updates timezone and json on an existing submission. json is the
|
|
3774
|
+
* stored SurveyJS tree, including file-answer objects; file content
|
|
3775
|
+
* is rewritten through the same writer the web uses. form_definition_id
|
|
3776
|
+
* and user_id cannot change. Returns the same representation as show.
|
|
3777
|
+
*
|
|
3778
|
+
*
|
|
3779
|
+
* **Required scope:**
|
|
3780
|
+
*
|
|
3781
|
+
* `form_submissions:update`
|
|
3782
|
+
*
|
|
3783
|
+
*/
|
|
3784
|
+
static updateFormSubmission(options) {
|
|
3785
|
+
return (options.client ?? client).patch({
|
|
3786
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
3787
|
+
url: '/api/v1/form_submissions/{id}',
|
|
3788
|
+
...options,
|
|
3789
|
+
headers: {
|
|
3790
|
+
'Content-Type': 'application/json',
|
|
3791
|
+
...options.headers
|
|
3792
|
+
}
|
|
3793
|
+
});
|
|
3794
|
+
}
|
|
3704
3795
|
}
|
|
3705
3796
|
export class Groups {
|
|
3706
3797
|
/**
|
|
@@ -3989,6 +4080,29 @@ export class Jobs {
|
|
|
3989
4080
|
}
|
|
3990
4081
|
});
|
|
3991
4082
|
}
|
|
4083
|
+
/**
|
|
4084
|
+
* Delete form assignment task on job
|
|
4085
|
+
*
|
|
4086
|
+
* Ends the open incomplete permanent copy of this nested
|
|
4087
|
+
* form-completion task, the same mutation as the web unassign
|
|
4088
|
+
* control. Recurrence stays on PATCH. A copy that is not an
|
|
4089
|
+
* incomplete permanent copy is refused with
|
|
4090
|
+
* `not_incomplete_permanent_copy`. A missing, misnested, or
|
|
4091
|
+
* out-of-scope id reads as not found. Returns `204`.
|
|
4092
|
+
*
|
|
4093
|
+
*
|
|
4094
|
+
* **Required scope:**
|
|
4095
|
+
*
|
|
4096
|
+
* `jobs.form_assignment_tasks:delete`
|
|
4097
|
+
*
|
|
4098
|
+
*/
|
|
4099
|
+
static deleteJobFormAssignmentTask(options) {
|
|
4100
|
+
return (options.client ?? client).delete({
|
|
4101
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4102
|
+
url: '/api/v1/jobs/{job_id}/form_assignment_tasks/{id}',
|
|
4103
|
+
...options
|
|
4104
|
+
});
|
|
4105
|
+
}
|
|
3992
4106
|
/**
|
|
3993
4107
|
* Show form assignment task on job
|
|
3994
4108
|
*
|
|
@@ -4039,7 +4153,8 @@ export class Jobs {
|
|
|
4039
4153
|
* Returns the good-faith-effort exceptions nested on the named job. A missing
|
|
4040
4154
|
* or out-of-scope job reads as not found. A visible job with no exceptions,
|
|
4041
4155
|
* including one that does not track apprenticeship, returns an empty list.
|
|
4042
|
-
* Ordered by request_start_date descending then id.
|
|
4156
|
+
* Ordered by request_start_date descending then id. Proof document slots are
|
|
4157
|
+
* always present as `null` or a document object.
|
|
4043
4158
|
*
|
|
4044
4159
|
*
|
|
4045
4160
|
* **Required scope:**
|
|
@@ -4054,11 +4169,61 @@ export class Jobs {
|
|
|
4054
4169
|
...options
|
|
4055
4170
|
});
|
|
4056
4171
|
}
|
|
4172
|
+
/**
|
|
4173
|
+
* Create good-faith effort exception
|
|
4174
|
+
*
|
|
4175
|
+
* Creates a good-faith-effort exception on the named job. `job_id` is the path
|
|
4176
|
+
* only. Scalar fields match GET; send minutes, not the web form's
|
|
4177
|
+
* `hours_per_apprentice`. Proof files attach through
|
|
4178
|
+
* `request_letter_signed_id`, `submission_proof_signed_id`,
|
|
4179
|
+
* `response_letter_signed_id`, and `no_availability_proof_signed_id` minted by
|
|
4180
|
+
* `POST /api/v1/direct_uploads` naming
|
|
4181
|
+
* `jobs.pwa.apprenticeship.good_faith_effort_exceptions`; when any of those
|
|
4182
|
+
* keys is present, `performed_by_user_id` is required. Model validations are
|
|
4183
|
+
* the 422 source. A missing or out-of-scope job reads as not found.
|
|
4184
|
+
*
|
|
4185
|
+
*
|
|
4186
|
+
* **Required scope:**
|
|
4187
|
+
*
|
|
4188
|
+
* `jobs.pwa.apprenticeship.good_faith_effort_exceptions:create`
|
|
4189
|
+
*
|
|
4190
|
+
*/
|
|
4191
|
+
static createGoodFaithEffortException(options) {
|
|
4192
|
+
return (options.client ?? client).post({
|
|
4193
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4194
|
+
url: '/api/v1/jobs/{job_id}/pwa/apprenticeship/good_faith_effort_exceptions',
|
|
4195
|
+
...options,
|
|
4196
|
+
headers: {
|
|
4197
|
+
'Content-Type': 'application/json',
|
|
4198
|
+
...options.headers
|
|
4199
|
+
}
|
|
4200
|
+
});
|
|
4201
|
+
}
|
|
4202
|
+
/**
|
|
4203
|
+
* Delete good-faith effort exception
|
|
4204
|
+
*
|
|
4205
|
+
* Removes the good-faith-effort exception nested on the named job. A missing,
|
|
4206
|
+
* misnested, or out-of-scope id reads as not found.
|
|
4207
|
+
*
|
|
4208
|
+
*
|
|
4209
|
+
* **Required scope:**
|
|
4210
|
+
*
|
|
4211
|
+
* `jobs.pwa.apprenticeship.good_faith_effort_exceptions:delete`
|
|
4212
|
+
*
|
|
4213
|
+
*/
|
|
4214
|
+
static deleteGoodFaithEffortException(options) {
|
|
4215
|
+
return (options.client ?? client).delete({
|
|
4216
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4217
|
+
url: '/api/v1/jobs/{job_id}/pwa/apprenticeship/good_faith_effort_exceptions/{id}',
|
|
4218
|
+
...options
|
|
4219
|
+
});
|
|
4220
|
+
}
|
|
4057
4221
|
/**
|
|
4058
4222
|
* Get good-faith effort exception
|
|
4059
4223
|
*
|
|
4060
4224
|
* Returns one good-faith-effort exception nested on the named job. A missing,
|
|
4061
|
-
* misnested, or out-of-scope id reads as not found.
|
|
4225
|
+
* misnested, or out-of-scope id reads as not found. Proof document slots are
|
|
4226
|
+
* always present as `null` or a document object.
|
|
4062
4227
|
*
|
|
4063
4228
|
*
|
|
4064
4229
|
* **Required scope:**
|
|
@@ -4073,6 +4238,100 @@ export class Jobs {
|
|
|
4073
4238
|
...options
|
|
4074
4239
|
});
|
|
4075
4240
|
}
|
|
4241
|
+
/**
|
|
4242
|
+
* Update good-faith effort exception
|
|
4243
|
+
*
|
|
4244
|
+
* Updates a good-faith-effort exception nested on the named job. Omit a field
|
|
4245
|
+
* to preserve it. Omit a proof signed-id key to keep the stored file; replacing
|
|
4246
|
+
* a populated slot keeps the original creator. A missing, misnested, or
|
|
4247
|
+
* out-of-scope id reads as not found.
|
|
4248
|
+
*
|
|
4249
|
+
*
|
|
4250
|
+
* **Required scope:**
|
|
4251
|
+
*
|
|
4252
|
+
* `jobs.pwa.apprenticeship.good_faith_effort_exceptions:update`
|
|
4253
|
+
*
|
|
4254
|
+
*/
|
|
4255
|
+
static updateGoodFaithEffortException(options) {
|
|
4256
|
+
return (options.client ?? client).patch({
|
|
4257
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4258
|
+
url: '/api/v1/jobs/{job_id}/pwa/apprenticeship/good_faith_effort_exceptions/{id}',
|
|
4259
|
+
...options,
|
|
4260
|
+
headers: {
|
|
4261
|
+
'Content-Type': 'application/json',
|
|
4262
|
+
...options.headers
|
|
4263
|
+
}
|
|
4264
|
+
});
|
|
4265
|
+
}
|
|
4266
|
+
/**
|
|
4267
|
+
* List WH-347 exports
|
|
4268
|
+
*
|
|
4269
|
+
* Returns the job-scoped WH-347 certified-payroll exports nested on the named
|
|
4270
|
+
* job. A missing or out-of-scope job reads as not found. A visible job with no
|
|
4271
|
+
* exports returns an empty list. Ordered by created_at descending then id.
|
|
4272
|
+
* Read-only. Poll a member GET for generation status and the file URL.
|
|
4273
|
+
*
|
|
4274
|
+
*
|
|
4275
|
+
* **Required scope:**
|
|
4276
|
+
*
|
|
4277
|
+
* `jobs.pwa.certified_payrolls.wh347_exports:read`
|
|
4278
|
+
*
|
|
4279
|
+
*/
|
|
4280
|
+
static listWh347Exports(options) {
|
|
4281
|
+
return (options.client ?? client).get({
|
|
4282
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4283
|
+
url: '/api/v1/jobs/{job_id}/pwa/certified_payrolls/wh347_exports',
|
|
4284
|
+
...options
|
|
4285
|
+
});
|
|
4286
|
+
}
|
|
4287
|
+
/**
|
|
4288
|
+
* Create WH-347 export
|
|
4289
|
+
*
|
|
4290
|
+
* Enqueues a job-scoped WH-347 certified-payroll export over `start_date`..
|
|
4291
|
+
* `end_date`. Returns the pending export (201); poll the member GET for
|
|
4292
|
+
* generation status and the file URL. Requires a user-scoped key. A job
|
|
4293
|
+
* that does not offer WH-347 is 422 `certified_payroll_format_unavailable`.
|
|
4294
|
+
* A window with no reportable pay periods is 422 `nothing_exportable`.
|
|
4295
|
+
* Does not start DocuSeal signing.
|
|
4296
|
+
*
|
|
4297
|
+
*
|
|
4298
|
+
* **Required scope:**
|
|
4299
|
+
*
|
|
4300
|
+
* `jobs.pwa.certified_payrolls.wh347_exports:create`
|
|
4301
|
+
*
|
|
4302
|
+
*/
|
|
4303
|
+
static createWh347Export(options) {
|
|
4304
|
+
return (options.client ?? client).post({
|
|
4305
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4306
|
+
url: '/api/v1/jobs/{job_id}/pwa/certified_payrolls/wh347_exports',
|
|
4307
|
+
...options,
|
|
4308
|
+
headers: {
|
|
4309
|
+
'Content-Type': 'application/json',
|
|
4310
|
+
...options.headers
|
|
4311
|
+
}
|
|
4312
|
+
});
|
|
4313
|
+
}
|
|
4314
|
+
/**
|
|
4315
|
+
* Get WH-347 export
|
|
4316
|
+
*
|
|
4317
|
+
* Returns one job-scoped WH-347 export nested on the named job. Poll this
|
|
4318
|
+
* document for generation status; `file` may be null until the file is attached,
|
|
4319
|
+
* including when status is `success`.
|
|
4320
|
+
* A missing, misnested, or out-of-scope id reads as not found. Read-only.
|
|
4321
|
+
*
|
|
4322
|
+
*
|
|
4323
|
+
* **Required scope:**
|
|
4324
|
+
*
|
|
4325
|
+
* `jobs.pwa.certified_payrolls.wh347_exports:read`
|
|
4326
|
+
*
|
|
4327
|
+
*/
|
|
4328
|
+
static getWh347Export(options) {
|
|
4329
|
+
return (options.client ?? client).get({
|
|
4330
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4331
|
+
url: '/api/v1/jobs/{job_id}/pwa/certified_payrolls/wh347_exports/{id}',
|
|
4332
|
+
...options
|
|
4333
|
+
});
|
|
4334
|
+
}
|
|
4076
4335
|
/**
|
|
4077
4336
|
* List cure payments
|
|
4078
4337
|
*
|
|
@@ -4080,7 +4339,7 @@ export class Jobs {
|
|
|
4080
4339
|
* or out-of-scope job reads as not found. A visible job with no
|
|
4081
4340
|
* payments, including one that does not track federal PWA, returns
|
|
4082
4341
|
* an empty list. Ordered by paid_on_date descending, then
|
|
4083
|
-
* created_at descending, then id.
|
|
4342
|
+
* created_at descending, then id.
|
|
4084
4343
|
*
|
|
4085
4344
|
*
|
|
4086
4345
|
* **Required scope:**
|
|
@@ -4095,11 +4354,58 @@ export class Jobs {
|
|
|
4095
4354
|
...options
|
|
4096
4355
|
});
|
|
4097
4356
|
}
|
|
4357
|
+
/**
|
|
4358
|
+
* Create a cure payment
|
|
4359
|
+
*
|
|
4360
|
+
* Creates a PWA cure payment on the named job. `job_id` comes from the
|
|
4361
|
+
* path. `type`, `amount_cents`, the three dates, and `performed_by_user_id`
|
|
4362
|
+
* are required. `type` is the stored STI class name and is create-only.
|
|
4363
|
+
* The attestation file attaches through `attestation_signed_id` minted by
|
|
4364
|
+
* `POST /api/v1/direct_uploads` naming `jobs.pwa.cure_payments`. A missing
|
|
4365
|
+
* or out-of-scope job or filer reads as not found. Model validations
|
|
4366
|
+
* return 422. Undeclared body keys return 400.
|
|
4367
|
+
*
|
|
4368
|
+
*
|
|
4369
|
+
* **Required scope:**
|
|
4370
|
+
*
|
|
4371
|
+
* `jobs.pwa.cure_payments:create`
|
|
4372
|
+
*
|
|
4373
|
+
*/
|
|
4374
|
+
static createCurePayment(options) {
|
|
4375
|
+
return (options.client ?? client).post({
|
|
4376
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4377
|
+
url: '/api/v1/jobs/{job_id}/pwa/cure_payments',
|
|
4378
|
+
...options,
|
|
4379
|
+
headers: {
|
|
4380
|
+
'Content-Type': 'application/json',
|
|
4381
|
+
...options.headers
|
|
4382
|
+
}
|
|
4383
|
+
});
|
|
4384
|
+
}
|
|
4385
|
+
/**
|
|
4386
|
+
* Delete a cure payment
|
|
4387
|
+
*
|
|
4388
|
+
* Removes the PWA cure payment nested on the named job. A missing or
|
|
4389
|
+
* misnested id reads as not found.
|
|
4390
|
+
*
|
|
4391
|
+
*
|
|
4392
|
+
* **Required scope:**
|
|
4393
|
+
*
|
|
4394
|
+
* `jobs.pwa.cure_payments:delete`
|
|
4395
|
+
*
|
|
4396
|
+
*/
|
|
4397
|
+
static deleteCurePayment(options) {
|
|
4398
|
+
return (options.client ?? client).delete({
|
|
4399
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4400
|
+
url: '/api/v1/jobs/{job_id}/pwa/cure_payments/{id}',
|
|
4401
|
+
...options
|
|
4402
|
+
});
|
|
4403
|
+
}
|
|
4098
4404
|
/**
|
|
4099
4405
|
* Get cure payment
|
|
4100
4406
|
*
|
|
4101
4407
|
* Returns one PWA cure payment nested on the named job. A missing,
|
|
4102
|
-
* misnested, or out-of-scope id reads as not found.
|
|
4408
|
+
* misnested, or out-of-scope id reads as not found.
|
|
4103
4409
|
*
|
|
4104
4410
|
*
|
|
4105
4411
|
* **Required scope:**
|
|
@@ -4114,6 +4420,33 @@ export class Jobs {
|
|
|
4114
4420
|
...options
|
|
4115
4421
|
});
|
|
4116
4422
|
}
|
|
4423
|
+
/**
|
|
4424
|
+
* Update a cure payment
|
|
4425
|
+
*
|
|
4426
|
+
* Updates a PWA cure payment nested on the named job. Omit a field to
|
|
4427
|
+
* preserve it. `type` is create-only; sending it returns 400. Omit
|
|
4428
|
+
* `attestation_signed_id` to keep the stored file; send it with
|
|
4429
|
+
* `performed_by_user_id` to create or replace the attestation. Replacing
|
|
4430
|
+
* a populated slot keeps the original document id and creator. A missing
|
|
4431
|
+
* or misnested id reads as not found.
|
|
4432
|
+
*
|
|
4433
|
+
*
|
|
4434
|
+
* **Required scope:**
|
|
4435
|
+
*
|
|
4436
|
+
* `jobs.pwa.cure_payments:update`
|
|
4437
|
+
*
|
|
4438
|
+
*/
|
|
4439
|
+
static updateCurePayment(options) {
|
|
4440
|
+
return (options.client ?? client).patch({
|
|
4441
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
4442
|
+
url: '/api/v1/jobs/{job_id}/pwa/cure_payments/{id}',
|
|
4443
|
+
...options,
|
|
4444
|
+
headers: {
|
|
4445
|
+
'Content-Type': 'application/json',
|
|
4446
|
+
...options.headers
|
|
4447
|
+
}
|
|
4448
|
+
});
|
|
4449
|
+
}
|
|
4117
4450
|
/**
|
|
4118
4451
|
* List sites for job
|
|
4119
4452
|
*
|
|
@@ -4416,7 +4749,8 @@ export class ProductionJobScopePrices {
|
|
|
4416
4749
|
* manager, or field lead of the company that owns the job,
|
|
4417
4750
|
* receive `unit_price_cents` and `contracted_count`. Other user
|
|
4418
4751
|
* keys, held by crew on the job, receive the same rows
|
|
4419
|
-
* without those two fields.
|
|
4752
|
+
* without those two fields. A present `unit_price_cents` is an
|
|
4753
|
+
* exact decimal string, or null when the current price is unknown.
|
|
4420
4754
|
*
|
|
4421
4755
|
*
|
|
4422
4756
|
* **Required scope:**
|
|
@@ -4436,9 +4770,10 @@ export class ProductionJobScopePrices {
|
|
|
4436
4770
|
*
|
|
4437
4771
|
* Creates a scope price on the URL's job. The body accepts only `scope_kind`,
|
|
4438
4772
|
* `unit_price_cents`, `contracted_count`, and `unit_of_measure`. Undeclared keys,
|
|
4439
|
-
* including the retired dollar `unit_price`, or a missing `scope_kind`
|
|
4440
|
-
* `
|
|
4441
|
-
*
|
|
4773
|
+
* including the retired dollar `unit_price`, or a missing `scope_kind` return
|
|
4774
|
+
* `400`. Omit `unit_price_cents` or send null for an unknown price; "0" is a
|
|
4775
|
+
* known zero. Supplied nonnull prices must be nonnegative decimal strings;
|
|
4776
|
+
* blank, numeric, negative, or wrong-typed prices return `422` without a write.
|
|
4442
4777
|
*
|
|
4443
4778
|
*
|
|
4444
4779
|
* **Required scope:**
|
|
@@ -4480,7 +4815,8 @@ export class ProductionJobScopePrices {
|
|
|
4480
4815
|
* manager, or field lead of the company that owns the job,
|
|
4481
4816
|
* receive `unit_price_cents` and `contracted_count`. Other user
|
|
4482
4817
|
* keys, held by crew on the job, receive the price without
|
|
4483
|
-
* those two fields.
|
|
4818
|
+
* those two fields. A present `unit_price_cents` is an exact
|
|
4819
|
+
* decimal string, or null when the current price is unknown.
|
|
4484
4820
|
*
|
|
4485
4821
|
*
|
|
4486
4822
|
* **Required scope:**
|
|
@@ -4499,9 +4835,11 @@ export class ProductionJobScopePrices {
|
|
|
4499
4835
|
* Update production job scope price
|
|
4500
4836
|
*
|
|
4501
4837
|
* Updates only the supplied `scope_kind`, `unit_price_cents`, `contracted_count`,
|
|
4502
|
-
* and `unit_of_measure
|
|
4503
|
-
*
|
|
4504
|
-
*
|
|
4838
|
+
* and `unit_of_measure`. Omission preserves the stored value; null
|
|
4839
|
+
* `unit_price_cents` clears the price to unknown, and null `contracted_count`
|
|
4840
|
+
* clears the target. Undeclared keys, including the retired dollar `unit_price`,
|
|
4841
|
+
* return `400`. Invalid supplied values return `422` without changing the scope
|
|
4842
|
+
* price. Prices remain nonnegative decimal strings; "0" is a known zero.
|
|
4505
4843
|
* The job stays on the URL.
|
|
4506
4844
|
*
|
|
4507
4845
|
*
|
|
@@ -5220,6 +5558,7 @@ export class JobWageDeterminations {
|
|
|
5220
5558
|
* at once, so it moves every version rather than applying from
|
|
5221
5559
|
* `effective_from`. A determination cascaded from a project mirrors that
|
|
5222
5560
|
* project's determination and cannot be edited here — change it on the project.
|
|
5561
|
+
* Re-pointing a journeyworker-basis determination also moves the apprentice determinations that follow it.
|
|
5223
5562
|
*
|
|
5224
5563
|
* Conditional: send the determination's `ETag` as `If-Match`.
|
|
5225
5564
|
*
|
|
@@ -5358,6 +5697,30 @@ export class OversiteFeatureFormAssignmentTasks {
|
|
|
5358
5697
|
}
|
|
5359
5698
|
});
|
|
5360
5699
|
}
|
|
5700
|
+
/**
|
|
5701
|
+
* Delete form assignment task on feature
|
|
5702
|
+
*
|
|
5703
|
+
* Ends the open incomplete permanent copy of this nested
|
|
5704
|
+
* form-completion task, the same mutation as the web unassign
|
|
5705
|
+
* control. Recurrence stays on PATCH. A copy that is not an
|
|
5706
|
+
* incomplete permanent copy is refused with
|
|
5707
|
+
* `not_incomplete_permanent_copy`. A missing, misnested, or
|
|
5708
|
+
* other-company id on this shared feature reads as not found.
|
|
5709
|
+
* Returns `204`.
|
|
5710
|
+
*
|
|
5711
|
+
*
|
|
5712
|
+
* **Required scope:**
|
|
5713
|
+
*
|
|
5714
|
+
* `oversite.sites.features.form_assignment_tasks:delete`
|
|
5715
|
+
*
|
|
5716
|
+
*/
|
|
5717
|
+
static deleteFeatureFormAssignmentTask(options) {
|
|
5718
|
+
return (options.client ?? client).delete({
|
|
5719
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
5720
|
+
url: '/api/v1/oversite/sites/{site_id}/features/{feature_id}/form_assignment_tasks/{id}',
|
|
5721
|
+
...options
|
|
5722
|
+
});
|
|
5723
|
+
}
|
|
5361
5724
|
/**
|
|
5362
5725
|
* Show form assignment task on feature
|
|
5363
5726
|
*
|
|
@@ -5453,6 +5816,30 @@ export class OversiteSiteFormAssignmentTasks {
|
|
|
5453
5816
|
}
|
|
5454
5817
|
});
|
|
5455
5818
|
}
|
|
5819
|
+
/**
|
|
5820
|
+
* Delete form assignment task on site
|
|
5821
|
+
*
|
|
5822
|
+
* Ends the open incomplete permanent copy of this nested
|
|
5823
|
+
* form-completion task, the same mutation as the web unassign
|
|
5824
|
+
* control. Recurrence stays on PATCH. A copy that is not an
|
|
5825
|
+
* incomplete permanent copy is refused with
|
|
5826
|
+
* `not_incomplete_permanent_copy`. A missing, misnested, or
|
|
5827
|
+
* other-company id on this shared site reads as not found.
|
|
5828
|
+
* Returns `204`.
|
|
5829
|
+
*
|
|
5830
|
+
*
|
|
5831
|
+
* **Required scope:**
|
|
5832
|
+
*
|
|
5833
|
+
* `oversite.sites.form_assignment_tasks:delete`
|
|
5834
|
+
*
|
|
5835
|
+
*/
|
|
5836
|
+
static deleteSiteFormAssignmentTask(options) {
|
|
5837
|
+
return (options.client ?? client).delete({
|
|
5838
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
5839
|
+
url: '/api/v1/oversite/sites/{site_id}/form_assignment_tasks/{id}',
|
|
5840
|
+
...options
|
|
5841
|
+
});
|
|
5842
|
+
}
|
|
5456
5843
|
/**
|
|
5457
5844
|
* Show form assignment task on site
|
|
5458
5845
|
*
|
|
@@ -7294,8 +7681,10 @@ export class PerDiems {
|
|
|
7294
7681
|
* List per diems
|
|
7295
7682
|
*
|
|
7296
7683
|
* List the per diems configured for the company — the named daily allowances
|
|
7297
|
-
* (meals, lodging, travel) available to attach to workers' time. Returned
|
|
7298
|
-
* first; narrow the results with the `filter[...]` query parameters.
|
|
7684
|
+
* (meals, lodging, travel) available to attach to workers' time. Returned oldest
|
|
7685
|
+
* first; narrow the results with the `filter[...]` query parameters. Company keys
|
|
7686
|
+
* and the user keys of company admins and managers can list the catalog; other
|
|
7687
|
+
* user keys are refused with `403`.
|
|
7299
7688
|
*
|
|
7300
7689
|
*
|
|
7301
7690
|
* **Required scope:**
|
|
@@ -7357,7 +7746,9 @@ export class PerDiems {
|
|
|
7357
7746
|
/**
|
|
7358
7747
|
* Show per diem
|
|
7359
7748
|
*
|
|
7360
|
-
* Fetch a single per diem by id.
|
|
7749
|
+
* Fetch a single per diem by id. Company keys and the user keys of company
|
|
7750
|
+
* admins and managers can read it; other user keys are refused with `403`.
|
|
7751
|
+
*
|
|
7361
7752
|
*
|
|
7362
7753
|
* **Required scope:**
|
|
7363
7754
|
*
|
|
@@ -8416,6 +8807,7 @@ export class ProjectWageDeterminations {
|
|
|
8416
8807
|
* `pwa_trade_id` is the exception: a trade regroups the whole determination
|
|
8417
8808
|
* at once, so it moves every version rather than applying from
|
|
8418
8809
|
* `effective_from`. Changes synchronize to linked job wage determinations.
|
|
8810
|
+
* Re-pointing a journeyworker-basis determination also moves the apprentice determinations that follow it.
|
|
8419
8811
|
*
|
|
8420
8812
|
* Conditional: send the determination's `ETag` as `If-Match`.
|
|
8421
8813
|
*
|
|
@@ -8472,14 +8864,17 @@ export class Projects {
|
|
|
8472
8864
|
* prevailing-wage lock-in / beginning-of-construction / placed-in-service dates)
|
|
8473
8865
|
* and `asset_owner` apply only while `federal_pwa_mode` is not `none`, so sending
|
|
8474
8866
|
* one of them on a project that tracks no federal PWA — even as null — returns
|
|
8475
|
-
* 422.
|
|
8476
|
-
* `
|
|
8477
|
-
*
|
|
8478
|
-
*
|
|
8479
|
-
*
|
|
8480
|
-
*
|
|
8481
|
-
*
|
|
8482
|
-
*
|
|
8867
|
+
* 422. IRA evidence files attach through `lock_in_date_doc_signed_id`,
|
|
8868
|
+
* `beginning_of_construction_doc_signed_id`, and `placed_in_service_doc_signed_id`
|
|
8869
|
+
* minted by `POST /api/v1/direct_uploads` naming `projects`; when any of those
|
|
8870
|
+
* keys is present, `performed_by_user_id` is required. `parent_id` may name a
|
|
8871
|
+
* project visible to the API key's policy, `participating_company_ids` is the
|
|
8872
|
+
* complete set of participating companies, and `manager_user_ids` is the complete
|
|
8873
|
+
* set of project managers (each a manager of the owning company). Remove a
|
|
8874
|
+
* participant's jobs before removing it from this set. Returns 201 with the
|
|
8875
|
+
* project; unknown or inaccessible parent, company, manager, or filer user IDs
|
|
8876
|
+
* return 404, and invalid attributes or relationships return 422. Undeclared
|
|
8877
|
+
* body keys return 400 before any project or relationship is saved.
|
|
8483
8878
|
*
|
|
8484
8879
|
*
|
|
8485
8880
|
* **Required scope:**
|
|
@@ -8528,7 +8923,12 @@ export class Projects {
|
|
|
8528
8923
|
* dates) and `asset_owner` apply only while `federal_pwa_mode` is not `none`:
|
|
8529
8924
|
* switching it to `none` clears the stored values and forces `asset_owner`
|
|
8530
8925
|
* false, and sending one of them while federal tracking is off — even as null —
|
|
8531
|
-
* returns 422.
|
|
8926
|
+
* returns 422. IRA evidence files attach through `lock_in_date_doc_signed_id`,
|
|
8927
|
+
* `beginning_of_construction_doc_signed_id`, and `placed_in_service_doc_signed_id`
|
|
8928
|
+
* minted by `POST /api/v1/direct_uploads` naming `projects`; omit a key to keep
|
|
8929
|
+
* the stored file, and send `performed_by_user_id` when any signed id is present.
|
|
8930
|
+
* Replacing a populated slot keeps the original `created_by_user_id`.
|
|
8931
|
+
* `budget_currency` defaults to USD when blank. `parent_id` moves
|
|
8532
8932
|
* or detaches the project; a project whose parent no longer lists its owner
|
|
8533
8933
|
* still accepts updates that keep that parent. `participating_company_ids`
|
|
8534
8934
|
* replaces the complete set of participating companies. `manager_user_ids`
|
|
@@ -8723,10 +9123,16 @@ export class Users {
|
|
|
8723
9123
|
/**
|
|
8724
9124
|
* List scheduled compensation changes for user's employment
|
|
8725
9125
|
*
|
|
9126
|
+
* Deprecated: use `GET /api/v1/people/employments/{employment_id}/history` instead.
|
|
9127
|
+
* The successor is keyed by the employment's `id` and lists every version, newest first.
|
|
9128
|
+
*
|
|
9129
|
+
*
|
|
8726
9130
|
* **Required scope:**
|
|
8727
9131
|
*
|
|
8728
9132
|
* `users.companies.scheduled_changes:read`
|
|
8729
9133
|
*
|
|
9134
|
+
*
|
|
9135
|
+
* @deprecated
|
|
8730
9136
|
*/
|
|
8731
9137
|
static listUserCompanyScheduledChanges(options) {
|
|
8732
9138
|
return (options.client ?? client).get({
|
|
@@ -8738,10 +9144,16 @@ export class Users {
|
|
|
8738
9144
|
/**
|
|
8739
9145
|
* Create scheduled change to user's employment information
|
|
8740
9146
|
*
|
|
9147
|
+
* Deprecated: use `POST /api/v1/people/employments/{employment_id}/scheduled_changes` instead.
|
|
9148
|
+
* The successor is keyed by the employment's `id` and needs `If-Match`.
|
|
9149
|
+
*
|
|
9150
|
+
*
|
|
8741
9151
|
* **Required scope:**
|
|
8742
9152
|
*
|
|
8743
9153
|
* `users.companies.scheduled_changes:create`
|
|
8744
9154
|
*
|
|
9155
|
+
*
|
|
9156
|
+
* @deprecated
|
|
8745
9157
|
*/
|
|
8746
9158
|
static createUserCompanyScheduledChange(options) {
|
|
8747
9159
|
return (options.client ?? client).post({
|
|
@@ -8757,10 +9169,16 @@ export class Users {
|
|
|
8757
9169
|
/**
|
|
8758
9170
|
* Cancel scheduled compensation change (removes the future version from the timeline)
|
|
8759
9171
|
*
|
|
9172
|
+
* Deprecated: use `DELETE /api/v1/people/employments/{employment_id}/scheduled_changes/{effective_date}` instead.
|
|
9173
|
+
* The successor is keyed by the employment's `id` and the change's effective date, and needs `If-Match`.
|
|
9174
|
+
*
|
|
9175
|
+
*
|
|
8760
9176
|
* **Required scope:**
|
|
8761
9177
|
*
|
|
8762
9178
|
* `users.companies.scheduled_changes:delete`
|
|
8763
9179
|
*
|
|
9180
|
+
*
|
|
9181
|
+
* @deprecated
|
|
8764
9182
|
*/
|
|
8765
9183
|
static cancelUserCompanyScheduledChange(options) {
|
|
8766
9184
|
return (options.client ?? client).delete({
|
|
@@ -8772,10 +9190,16 @@ export class Users {
|
|
|
8772
9190
|
/**
|
|
8773
9191
|
* Update scheduled compensation change
|
|
8774
9192
|
*
|
|
9193
|
+
* Deprecated: use `PATCH /api/v1/people/employments/{employment_id}/scheduled_changes/{effective_date}` instead.
|
|
9194
|
+
* The successor is keyed by the employment's `id` and the change's effective date, and needs `If-Match`.
|
|
9195
|
+
*
|
|
9196
|
+
*
|
|
8775
9197
|
* **Required scope:**
|
|
8776
9198
|
*
|
|
8777
9199
|
* `users.companies.scheduled_changes:update`
|
|
8778
9200
|
*
|
|
9201
|
+
*
|
|
9202
|
+
* @deprecated
|
|
8779
9203
|
*/
|
|
8780
9204
|
static updateScheduledChange(options) {
|
|
8781
9205
|
return (options.client ?? client).patch({
|
|
@@ -9502,8 +9926,9 @@ export class TimeEntries {
|
|
|
9502
9926
|
* company's default timecodes), state, description, hourly_rate_cents (derived
|
|
9503
9927
|
* from the position/user default when omitted), and feature_ids. Supplying
|
|
9504
9928
|
* feature_ids — or setting feature_allocation_acknowledged true — satisfies a
|
|
9505
|
-
* job that requires a feature allocation.
|
|
9506
|
-
*
|
|
9929
|
+
* job that requires a feature allocation. The optional overtime premium cents inputs
|
|
9930
|
+
* set the complete tier premiums, additional to base hourly pay. Financial
|
|
9931
|
+
* rate inputs are admin only on user-scoped keys.
|
|
9507
9932
|
*
|
|
9508
9933
|
*
|
|
9509
9934
|
* **Required scope:**
|
|
@@ -9580,7 +10005,8 @@ export class TimeEntries {
|
|
|
9580
10005
|
* 422 unless confirm_allocation_conflict is sent true. The feature-allocation cap is
|
|
9581
10006
|
* enforced, and because a persisted feature_ids= writes its join rows
|
|
9582
10007
|
* immediately, a rejected save rolls them back within the enclosing
|
|
9583
|
-
* transaction.
|
|
10008
|
+
* transaction. Omitted overtime premium cents inputs keep their saved values; null
|
|
10009
|
+
* resets a tier to automatic. Financial rate inputs are admin only on user-scoped keys.
|
|
9584
10010
|
*
|
|
9585
10011
|
*
|
|
9586
10012
|
* **Required scope:**
|
|
@@ -10209,6 +10635,32 @@ export class TimeOffRequests {
|
|
|
10209
10635
|
...options
|
|
10210
10636
|
});
|
|
10211
10637
|
}
|
|
10638
|
+
/**
|
|
10639
|
+
* Create time off request
|
|
10640
|
+
*
|
|
10641
|
+
* Create a time-off request for a worker. Name the worker and the filer.
|
|
10642
|
+
* When they are the same person the request is born pending; otherwise it
|
|
10643
|
+
* is born approved with the filer stamped as reviewer and an Absence is
|
|
10644
|
+
* built in the background. Instants are the beginning of the first day and
|
|
10645
|
+
* the end of the last day in the pay-schedule timezone.
|
|
10646
|
+
*
|
|
10647
|
+
*
|
|
10648
|
+
* **Required scope:**
|
|
10649
|
+
*
|
|
10650
|
+
* `timekeeping.time_off_requests:create`
|
|
10651
|
+
*
|
|
10652
|
+
*/
|
|
10653
|
+
static createTimeOffRequest(options) {
|
|
10654
|
+
return (options.client ?? client).post({
|
|
10655
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
10656
|
+
url: '/api/v1/timekeeping/time_off_requests',
|
|
10657
|
+
...options,
|
|
10658
|
+
headers: {
|
|
10659
|
+
'Content-Type': 'application/json',
|
|
10660
|
+
...options.headers
|
|
10661
|
+
}
|
|
10662
|
+
});
|
|
10663
|
+
}
|
|
10212
10664
|
/**
|
|
10213
10665
|
* Show time off request
|
|
10214
10666
|
*
|
|
@@ -10228,6 +10680,30 @@ export class TimeOffRequests {
|
|
|
10228
10680
|
...options
|
|
10229
10681
|
});
|
|
10230
10682
|
}
|
|
10683
|
+
/**
|
|
10684
|
+
* Review time off request
|
|
10685
|
+
*
|
|
10686
|
+
* Approve, deny, or cancel a pending time-off request. The named filer is
|
|
10687
|
+
* the reviewer: only the worker may cancel, and nobody may approve or deny
|
|
10688
|
+
* their own row. Approving enqueues the Absence build.
|
|
10689
|
+
*
|
|
10690
|
+
*
|
|
10691
|
+
* **Required scope:**
|
|
10692
|
+
*
|
|
10693
|
+
* `timekeeping.time_off_requests.reviews:create`
|
|
10694
|
+
*
|
|
10695
|
+
*/
|
|
10696
|
+
static createReview(options) {
|
|
10697
|
+
return (options.client ?? client).post({
|
|
10698
|
+
security: [{ name: 'X-Api-Key', type: 'apiKey' }],
|
|
10699
|
+
url: '/api/v1/timekeeping/time_off_requests/{time_off_request_id}/reviews',
|
|
10700
|
+
...options,
|
|
10701
|
+
headers: {
|
|
10702
|
+
'Content-Type': 'application/json',
|
|
10703
|
+
...options.headers
|
|
10704
|
+
}
|
|
10705
|
+
});
|
|
10706
|
+
}
|
|
10231
10707
|
}
|
|
10232
10708
|
export class TimeSessions {
|
|
10233
10709
|
/**
|