@typeship-ax/cli 0.20.0 → 0.21.1

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.
Files changed (99) hide show
  1. package/AGENTS.md +3 -3
  2. package/README.md +2 -2
  3. package/api.json +7355 -6233
  4. package/api.md +332 -398
  5. package/dist/api-identity.d.ts.map +1 -1
  6. package/dist/api-identity.js +6 -1
  7. package/dist/cli.js +15 -15
  8. package/dist/core/http.d.ts +26 -14
  9. package/dist/core/http.d.ts.map +1 -1
  10. package/dist/core/http.js +90 -19
  11. package/dist/core/pagination.d.ts +8 -8
  12. package/dist/core/pagination.d.ts.map +1 -1
  13. package/dist/core/pagination.js +7 -16
  14. package/dist/errors.d.ts +4 -4
  15. package/dist/errors.d.ts.map +1 -1
  16. package/dist/errors.js +7 -7
  17. package/dist/index.d.ts +33 -19
  18. package/dist/index.d.ts.map +1 -1
  19. package/dist/index.js +37 -17
  20. package/dist/ops.d.ts +1 -1
  21. package/dist/ops.d.ts.map +1 -1
  22. package/dist/ops.js +39 -42
  23. package/dist/resources/api-keys.d.ts +10 -10
  24. package/dist/resources/api-keys.d.ts.map +1 -1
  25. package/dist/resources/api-keys.js +6 -6
  26. package/dist/resources/deliveries.d.ts +46 -0
  27. package/dist/resources/deliveries.d.ts.map +1 -0
  28. package/dist/resources/deliveries.js +70 -0
  29. package/dist/resources/drafts.d.ts +155 -0
  30. package/dist/resources/drafts.d.ts.map +1 -0
  31. package/dist/resources/drafts.js +230 -0
  32. package/dist/resources/files.d.ts +23 -0
  33. package/dist/resources/files.d.ts.map +1 -0
  34. package/dist/resources/files.js +38 -0
  35. package/dist/resources/generate.d.ts +14 -14
  36. package/dist/resources/generate.d.ts.map +1 -1
  37. package/dist/resources/generate.js +7 -7
  38. package/dist/resources/generations.d.ts +65 -21
  39. package/dist/resources/generations.d.ts.map +1 -1
  40. package/dist/resources/generations.js +67 -20
  41. package/dist/resources/organization.d.ts +18 -0
  42. package/dist/resources/organization.d.ts.map +1 -0
  43. package/dist/resources/{account.js → organization.js} +10 -10
  44. package/dist/resources/projects.d.ts +36 -126
  45. package/dist/resources/projects.d.ts.map +1 -1
  46. package/dist/resources/projects.js +21 -171
  47. package/dist/resources/publications.d.ts +46 -0
  48. package/dist/resources/publications.d.ts.map +1 -0
  49. package/dist/resources/publications.js +70 -0
  50. package/dist/resources/releases.d.ts +66 -0
  51. package/dist/resources/releases.d.ts.map +1 -0
  52. package/dist/resources/releases.js +101 -0
  53. package/dist/resources/spec-revisions.d.ts +85 -0
  54. package/dist/resources/spec-revisions.d.ts.map +1 -0
  55. package/dist/resources/spec-revisions.js +116 -0
  56. package/dist/resources/specs.d.ts +72 -0
  57. package/dist/resources/specs.d.ts.map +1 -0
  58. package/dist/resources/specs.js +107 -0
  59. package/dist/resources/targets.d.ts +42 -262
  60. package/dist/resources/targets.d.ts.map +1 -1
  61. package/dist/resources/targets.js +28 -407
  62. package/dist/schemas.d.ts.map +1 -1
  63. package/dist/schemas.js +149 -154
  64. package/dist/types.d.ts +1281 -1611
  65. package/dist/types.d.ts.map +1 -1
  66. package/dist/types.js +44 -49
  67. package/package.json +1 -1
  68. package/src/api-identity.ts +6 -2
  69. package/src/cli.ts +16 -16
  70. package/src/core/http.ts +89 -24
  71. package/src/core/pagination.ts +13 -23
  72. package/src/errors.ts +7 -7
  73. package/src/index.ts +41 -23
  74. package/src/ops.ts +40 -43
  75. package/src/resources/api-keys.ts +13 -16
  76. package/src/resources/deliveries.ts +139 -0
  77. package/src/resources/drafts.ts +422 -0
  78. package/src/resources/files.ts +68 -0
  79. package/src/resources/generate.ts +16 -19
  80. package/src/resources/generations.ts +146 -35
  81. package/src/resources/{account.ts → organization.ts} +14 -14
  82. package/src/resources/projects.ts +42 -337
  83. package/src/resources/publications.ts +139 -0
  84. package/src/resources/releases.ts +199 -0
  85. package/src/resources/spec-revisions.ts +237 -0
  86. package/src/resources/specs.ts +200 -0
  87. package/src/resources/targets.ts +57 -760
  88. package/src/schemas.ts +149 -154
  89. package/src/types.ts +1357 -1692
  90. package/dist/resources/account.d.ts +0 -18
  91. package/dist/resources/account.d.ts.map +0 -1
  92. package/dist/resources/definition-revisions.d.ts +0 -75
  93. package/dist/resources/definition-revisions.d.ts.map +0 -1
  94. package/dist/resources/definition-revisions.js +0 -142
  95. package/dist/resources/definitions.d.ts +0 -50
  96. package/dist/resources/definitions.d.ts.map +0 -1
  97. package/dist/resources/definitions.js +0 -73
  98. package/src/resources/definition-revisions.ts +0 -265
  99. package/src/resources/definitions.ts +0 -146
@@ -1,7 +1,7 @@
1
- import { HttpCore, type ApiResult, type RequestOptions } from "../core/http.js";
1
+ import { HttpCore, type RequestOptions } from "../core/http.js";
2
2
  import { PagePromise } from "../core/pagination.js";
3
3
  import { ResponseParseError, TransportError, UnexpectedApiError, ValidationError, BadGatewayError, BadRequestError, ConflictError, ForbiddenError, InternalServerError, NotFoundError, PayloadTooLargeError, PaymentRequiredError, PreconditionFailedError, RateLimitedError, UnauthorizedError, UnprocessableEntityError } from "../errors.js";
4
- import type { CreateProjectRequest, DeletedProjectRead, DiagnosticRemediationRead, DiagnosticRemediationRequest, DiagnosticReportRead, GenerateProjectRequest, GenerationBatchRead, GenerationSummaryRead, ProjectId, ProjectRead, ProjectSummaryRead, RepositoryIntegrationHealthRead, TargetId, UpdateProjectRequest } from "../types.js";
4
+ import type { CreateProjectRequest, DeletedProjectRead, GenerateProjectRequest, GenerationBatchRead, ProjectId, ProjectRead, ProjectSummaryRead, UpdateProjectRequest } from "../types.js";
5
5
  export declare class ProjectsResource {
6
6
  private readonly _core;
7
7
  constructor(_core: HttpCore);
@@ -15,7 +15,8 @@ export declare class ProjectsResource {
15
15
  /**
16
16
  * Create a project
17
17
  *
18
- * Creates a Project from a URL or GitHub Definition.
18
+ * Creates a Project from a URL or GitHub Spec.
19
+ * Automatic generation is enabled by default for a saved Project.
19
20
  *
20
21
  * Free includes one saved Project, all selected Targets, and the first 25 operations per Target,
21
22
  * with regeneration, history, delivery pull requests, and previews. Pro supports additional
@@ -24,15 +25,15 @@ export declare class ProjectsResource {
24
25
  * A `Idempotency-Key` UUID is generated per call (stable across retries) unless you pass one.
25
26
  * `POST /projects`
26
27
  */
27
- create(body: CreateProjectRequest, params?: ProjectsCreateParams, options?: RequestOptions): Promise<ApiResult<ProjectRead, ProjectsCreateError>>;
28
+ create(body: CreateProjectRequest, params?: ProjectsCreateParams, options?: RequestOptions): Promise<ProjectRead>;
28
29
  /**
29
- * Retrieve a project
30
+ * Get a project
30
31
  *
31
- * Returns the Project's settings and Definition ID. List its Targets separately to retrieve
32
- * Target configuration and Deliveries.
32
+ * Returns the Project's settings and Spec ID. List its Targets separately to retrieve Target
33
+ * configuration and Deliveries.
33
34
  * `GET /projects/{project_id}`
34
35
  */
35
- retrieve(projectId: ProjectId, options?: RequestOptions): Promise<ApiResult<ProjectRead, ProjectsRetrieveError>>;
36
+ get(projectId: ProjectId, options?: RequestOptions): Promise<ProjectRead>;
36
37
  /**
37
38
  * Delete a project
38
39
  *
@@ -43,16 +44,18 @@ export declare class ProjectsResource {
43
44
  * and If-Match.
44
45
  * `DELETE /projects/{project_id}`
45
46
  */
46
- delete(projectId: ProjectId, params?: ProjectsDeleteParams, options?: RequestOptions): Promise<ApiResult<DeletedProjectRead, ProjectsDeleteError>>;
47
+ delete(projectId: ProjectId, params?: ProjectsDeleteParams, options?: RequestOptions): Promise<DeletedProjectRead>;
47
48
  /**
48
49
  * Update a project
49
50
  *
50
51
  * Omitted fields keep their current values. A supplied config replaces the entire stored object;
51
52
  * null or an empty object clears it.
53
+ * With auto_generate enabled, changing shared config queues a Generation for each Target whose
54
+ * effective config changes. A queued or running Target reuses that Generation.
52
55
  * Omitting If-Match applies the update to the current resource; with If-Match, a stale ETag
53
56
  * returns 412 precondition_failed without saving.
54
57
  *
55
- * A `409 target_busy` means a Target is publishing. Retrieve the Project, wait for publication to
58
+ * A `409 target_busy` means a Target is publishing. Retrieve the Project, wait for publishing to
56
59
  * finish, reconcile your update, and retry.
57
60
  * A `502` response means the Project was saved, but an obsolete release pull request could not be
58
61
  * retired. Retrieve the Project and retry the same update to finish retiring reviews if that
@@ -61,72 +64,25 @@ export declare class ProjectsResource {
61
64
  * and If-Match.
62
65
  * `PATCH /projects/{project_id}`
63
66
  */
64
- update(projectId: ProjectId, body: UpdateProjectRequest, params?: ProjectsUpdateParams, options?: RequestOptions): Promise<ApiResult<ProjectRead, ProjectsUpdateError>>;
65
- /**
66
- * Analyze a project's latest Definition Revision
67
- *
68
- * Checks the latest Definition Revision after applying its saved patches. Each finding groups
69
- * affected locations under a stable rule ID. A suggested patch is included only when the
70
- * Definition provides enough information to determine the correction.
71
- * `GET /projects/{project_id}/diagnostics`
72
- */
73
- retrieveDiagnostics(projectId: ProjectId, options?: RequestOptions): Promise<ApiResult<DiagnosticReportRead, ProjectsRetrieveDiagnosticsError>>;
74
- /**
75
- * Refresh a project's Diagnostics from its configured source
76
- *
77
- * Fetches the configured source and returns updated Diagnostics. Creates a Definition Revision
78
- * only when the content changes. Does not generate Targets or use a metered generation.
79
- *
80
- * A `Idempotency-Key` UUID is generated per call (stable across retries) unless you pass one.
81
- * `POST /projects/{project_id}/diagnostics`
82
- */
83
- refreshDiagnostics(projectId: ProjectId, params?: ProjectsRefreshDiagnosticsParams, options?: RequestOptions): Promise<ApiResult<DiagnosticReportRead, ProjectsRefreshDiagnosticsError>>;
84
- /**
85
- * Apply exact, reviewed diagnostic remediations
86
- *
87
- * Applies reviewed patches from Diagnostics. For a repository source, opens or updates a source
88
- * pull request. For a URL source, saves Definition patches.
89
- *
90
- * Findings that need an API-owner decision return `422`. Read the finding's `authoring_brief` and
91
- * update the source instead.
92
- *
93
- * A `Idempotency-Key` UUID is generated per call (stable across retries) unless you pass one.
94
- * `POST /projects/{project_id}/diagnostics/remediations`
95
- */
96
- remediateDiagnostics(projectId: ProjectId, body: DiagnosticRemediationRequest, params?: ProjectsRemediateDiagnosticsParams, options?: RequestOptions): Promise<ApiResult<DiagnosticRemediationRead, ProjectsRemediateDiagnosticsError>>;
97
- /**
98
- * Diagnose a project's repository integrations
99
- *
100
- * Checks repository access, Definition readability, source-approval labels, and required checks.
101
- * Includes the latest webhook delivery so you can investigate missing updates.
102
- * `GET /projects/{project_id}/integration-health`
103
- */
104
- retrieveIntegrationHealth(projectId: ProjectId, options?: RequestOptions): Promise<ApiResult<RepositoryIntegrationHealthRead, ProjectsRetrieveIntegrationHealthError>>;
105
- /**
106
- * List a project's generations
107
- *
108
- * Auto-paginates: `for await (const item of …)` walks every page.
109
- * `GET /projects/{project_id}/generations`
110
- */
111
- listGenerations(projectId: ProjectId, params?: ProjectsListGenerationsParams, options?: RequestOptions): PagePromise<GenerationSummaryRead, ProjectsListGenerationsError>;
67
+ update(projectId: ProjectId, body: UpdateProjectRequest, params?: ProjectsUpdateParams, options?: RequestOptions): Promise<ProjectRead>;
112
68
  /**
113
69
  * Start generation for active Targets
114
70
  *
115
71
  * Queues one Generation per active Target and returns their IDs. Retrieve each Generation until
116
- * its status moves from `queued` to `running` and then `succeeded` or `failed`. `succeeded` means
72
+ * its status moves from `queued` to `running` and then `completed` or `failed`. `completed` means
117
73
  * generated files are saved; check Delivery and Draft status separately for repository delivery
118
74
  * and pull requests. A Target already queued or running is returned without starting another
119
75
  * Generation. A matching Idempotency-Key replay returns the same Generations with their current
120
76
  * statuses.
121
77
  *
122
- * If the package already matches a destination and no Draft is open, delivery reports `pr_status:
123
- * no_changes` without creating a commit, branch, or pull request. An existing Draft stays open.
124
- * Automatic generation uses the same workflow.
78
+ * If the package already matches a destination and no Draft is open, delivery creates no commit,
79
+ * branch, or pull request. An existing Draft stays open. Automatic generation uses the same
80
+ * workflow.
125
81
  *
126
82
  * A `Idempotency-Key` UUID is generated per call (stable across retries) unless you pass one.
127
- * `POST /projects/{project_id}/generations`
83
+ * `POST /projects/{project_id}/generate`
128
84
  */
129
- generate(projectId: ProjectId, body?: GenerateProjectRequest, params?: ProjectsGenerateParams, options?: RequestOptions): Promise<ApiResult<GenerationBatchRead, ProjectsGenerateError>>;
85
+ generate(projectId: ProjectId, body?: GenerateProjectRequest, params?: ProjectsGenerateParams, options?: RequestOptions): Promise<GenerationBatchRead>;
130
86
  }
131
87
  export interface ProjectsListParams {
132
88
  /**
@@ -137,28 +93,28 @@ export interface ProjectsListParams {
137
93
  */
138
94
  limit?: number;
139
95
  /**
140
- * Opaque cursor from the preceding page's next_cursor. Valid only for the same account,
96
+ * Opaque cursor from the preceding page's next_cursor. Valid only for the same organization,
141
97
  * operation, filters, and ordering that issued it. Omit to start at the first page. Empty,
142
98
  * malformed, or repeated cursors return 400 invalid_request. The page limit may change between
143
99
  * requests.
144
100
  */
145
101
  cursor?: string;
146
102
  }
147
- /** Every error `list` can produce, as a discriminated union. */
103
+ /** Typed errors `list` can throw. */
148
104
  export type ProjectsListError = BadRequestError | UnauthorizedError | ForbiddenError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
149
105
  export interface ProjectsCreateParams {
150
106
  /**
151
- * Identifies one logical write for 24 hours. The key is scoped to the authenticated account and
152
- * operation; account-less generation uses a hashed network identity. Retrying the same method,
153
- * path, query, If-Match header, and JSON body replays the original response. Reusing the key with
154
- * changed intent returns 409. After expiry the key starts a new write.
107
+ * Identifies one logical write for 24 hours. The key is scoped to the authenticated organization
108
+ * and operation; generation without an organization uses a hashed network identity. Retrying the
109
+ * same method, path, query, If-Match header, and JSON body replays the original response. Reusing
110
+ * the key with changed intent returns 409. After expiry the key starts a new write.
155
111
  */
156
112
  idempotencyKey?: string;
157
113
  }
158
- /** Every error `create` can produce, as a discriminated union. */
114
+ /** Typed errors `create` can throw. */
159
115
  export type ProjectsCreateError = BadRequestError | UnauthorizedError | PaymentRequiredError | ForbiddenError | ConflictError | UnprocessableEntityError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
160
- /** Every error `retrieve` can produce, as a discriminated union. */
161
- export type ProjectsRetrieveError = UnauthorizedError | ForbiddenError | NotFoundError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
116
+ /** Typed errors `get` can throw. */
117
+ export type ProjectsGetError = UnauthorizedError | ForbiddenError | NotFoundError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
162
118
  export interface ProjectsDeleteParams {
163
119
  /**
164
120
  * ETag from a preceding response. The write applies only if the resource still has that version;
@@ -167,7 +123,7 @@ export interface ProjectsDeleteParams {
167
123
  */
168
124
  ifMatch?: string;
169
125
  }
170
- /** Every error `delete` can produce, as a discriminated union. */
126
+ /** Typed errors `delete` can throw. */
171
127
  export type ProjectsDeleteError = BadRequestError | UnauthorizedError | ForbiddenError | NotFoundError | PreconditionFailedError | RateLimitedError | InternalServerError | BadGatewayError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
172
128
  export interface ProjectsUpdateParams {
173
129
  /**
@@ -177,63 +133,17 @@ export interface ProjectsUpdateParams {
177
133
  */
178
134
  ifMatch?: string;
179
135
  }
180
- /** Every error `update` can produce, as a discriminated union. */
136
+ /** Typed errors `update` can throw. */
181
137
  export type ProjectsUpdateError = BadRequestError | UnauthorizedError | PaymentRequiredError | ForbiddenError | NotFoundError | ConflictError | PreconditionFailedError | UnprocessableEntityError | RateLimitedError | InternalServerError | BadGatewayError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
182
- /** Every error `retrieveDiagnostics` can produce, as a discriminated union. */
183
- export type ProjectsRetrieveDiagnosticsError = UnauthorizedError | ForbiddenError | NotFoundError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
184
- export interface ProjectsRefreshDiagnosticsParams {
185
- /**
186
- * Identifies one logical write for 24 hours. The key is scoped to the authenticated account and
187
- * operation; account-less generation uses a hashed network identity. Retrying the same method,
188
- * path, query, If-Match header, and JSON body replays the original response. Reusing the key with
189
- * changed intent returns 409. After expiry the key starts a new write.
190
- */
191
- idempotencyKey?: string;
192
- }
193
- /** Every error `refreshDiagnostics` can produce, as a discriminated union. */
194
- export type ProjectsRefreshDiagnosticsError = BadRequestError | UnauthorizedError | ForbiddenError | NotFoundError | ConflictError | UnprocessableEntityError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
195
- export interface ProjectsRemediateDiagnosticsParams {
196
- /**
197
- * Identifies one logical write for 24 hours. The key is scoped to the authenticated account and
198
- * operation; account-less generation uses a hashed network identity. Retrying the same method,
199
- * path, query, If-Match header, and JSON body replays the original response. Reusing the key with
200
- * changed intent returns 409. After expiry the key starts a new write.
201
- */
202
- idempotencyKey?: string;
203
- }
204
- /** Every error `remediateDiagnostics` can produce, as a discriminated union. */
205
- export type ProjectsRemediateDiagnosticsError = BadRequestError | UnauthorizedError | ForbiddenError | NotFoundError | ConflictError | UnprocessableEntityError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
206
- /** Every error `retrieveIntegrationHealth` can produce, as a discriminated union. */
207
- export type ProjectsRetrieveIntegrationHealthError = UnauthorizedError | ForbiddenError | NotFoundError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
208
- export interface ProjectsListGenerationsParams {
209
- /**
210
- * Maximum number of resources to return. Omit for 20; otherwise supply base-10 digits
211
- * representing an integer from 1 to 100. Empty, malformed, or out-of-range values return 400
212
- * invalid_request. List query parameters must appear only once; unrecognized parameters also
213
- * return 400.
214
- */
215
- limit?: number;
216
- /**
217
- * Opaque cursor from the preceding page's next_cursor. Valid only for the same account,
218
- * operation, filters, and ordering that issued it. Omit to start at the first page. Empty,
219
- * malformed, or repeated cursors return 400 invalid_request. The page limit may change between
220
- * requests.
221
- */
222
- cursor?: string;
223
- /** Only generations for this persisted Target. */
224
- targetId?: TargetId;
225
- }
226
- /** Every error `listGenerations` can produce, as a discriminated union. */
227
- export type ProjectsListGenerationsError = BadRequestError | UnauthorizedError | ForbiddenError | NotFoundError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
228
138
  export interface ProjectsGenerateParams {
229
139
  /**
230
- * Identifies one logical write for 24 hours. The key is scoped to the authenticated account and
231
- * operation; account-less generation uses a hashed network identity. Retrying the same method,
232
- * path, query, If-Match header, and JSON body replays the original response. Reusing the key with
233
- * changed intent returns 409. After expiry the key starts a new write.
140
+ * Identifies one logical write for 24 hours. The key is scoped to the authenticated organization
141
+ * and operation; generation without an organization uses a hashed network identity. Retrying the
142
+ * same method, path, query, If-Match header, and JSON body replays the original response. Reusing
143
+ * the key with changed intent returns 409. After expiry the key starts a new write.
234
144
  */
235
145
  idempotencyKey?: string;
236
146
  }
237
- /** Every error `generate` can produce, as a discriminated union. */
147
+ /** Typed errors `generate` can throw. */
238
148
  export type ProjectsGenerateError = BadRequestError | UnauthorizedError | PaymentRequiredError | ForbiddenError | NotFoundError | ConflictError | PayloadTooLargeError | UnprocessableEntityError | RateLimitedError | InternalServerError | BadGatewayError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
239
149
  //# sourceMappingURL=projects.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"projects.d.ts","sourceRoot":"","sources":["../../src/resources/projects.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,QAAQ,EAAE,KAAK,SAAS,EAAE,KAAK,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAChF,OAAO,EAAY,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EACL,kBAAkB,EAClB,cAAc,EACd,kBAAkB,EAClB,eAAe,EACf,eAAe,EACf,eAAe,EACf,aAAa,EACb,cAAc,EACd,mBAAmB,EACnB,aAAa,EACb,oBAAoB,EACpB,oBAAoB,EACpB,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,EACjB,wBAAwB,EACzB,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,EACV,oBAAoB,EAEpB,kBAAkB,EAElB,yBAAyB,EACzB,4BAA4B,EAE5B,oBAAoB,EACpB,s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AAC;CACzB;AAED,oEAAoE;AACpE,MAAM,MAAM,qBAAqB,GAC7B,eAAe,GACf,iBAAiB,GACjB,oBAAoB,GACpB,cAAc,GACd,aAAa,GACb,aAAa,GACb,oBAAoB,GACpB,wBAAwB,GACxB,gBAAgB,GAChB,mBAAmB,GACnB,eAAe,GACf,kBAAkB,GAClB,kBAAkB,GAClB,cAAc,GACd,eAAe,CAAC"}
1
+ {"version":3,"file":"projects.d.ts","sourceRoot":"","sources":["../../src/resources/projects.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,QAAQ,EAAE,KAAK,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAChE,OAAO,EAAY,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EACL,kBAAkB,EAClB,cAAc,EACd,kBAAkB,EAClB,eAAe,EACf,eAAe,EACf,eAAe,EACf,aAAa,EACb,cAAc,EACd,mBAAmB,EACnB,aAAa,EACb,oBAAoB,EACpB,oBAAoB,EACpB,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,EACjB,wBAAwB,EACzB,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,EACV,oBAAoB,EAEpB,kBAAkB,EAClB,sBAAsB,EAEtB,mBAAmB,EAEnB,SAAS,EAGT,WAAW,EAEX,kBAAkB,EAClB,oBAAoB,EACrB,MAAM,aAAa,CAAC;AAErB,qBAAa,gBAAgB;IACf,OAAO,CAAC,QAAQ,CAAC,KAAK;gBAAL,KAAK,EAAE,QAAQ;IAC5C;;;;;OAKG;IACH,IAAI,CACF,MAAM,CAAC,EAAE,kBAAkB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,kBAAkB,EAAE,iBAAiB,CAAC;IA6BrD;;;;;;;;;;;;OAYG;IACG,MAAM,CACV,IAAI,EAAE,oBAAoB,EAC1B,MAAM,CAAC,EAAE,oBAAoB,EAC7B,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,WAAW,CAAC;IAyBvB;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eAAe,CAAC;AAEpB,oCAAoC;AACpC,MAAM,MAAM,gBAAgB,GACxB,iBAAiB,GACjB,cAAc,GACd,aAAa,GACb,gBAAgB,GAChB,mBAAmB,GACnB,kBAAkB,GAClB,kBAAkB,GAClB,cAAc,GACd,eAAe,CAAC;AAEpB,MAAM,WAAW,oBAAoB;IACnC;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,uCAAuC;AACvC,MAAM,MAAM,mBAAmB,GAC3B,eAAe,GACf,iBAAiB,GACjB,cAAc,GACd,aAAa,GACb,uBAAuB,GACvB,gBAAgB,GAChB,mBAAmB,GACnB,eAAe,GACf,kBAAkB,GAClB,kBAAkB,GAClB,cAAc,GACd,eAAe,CAAC;AAEpB,MAAM,WAAW,oBAAoB;IACnC;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,uCAAuC;AACvC,MAAM,MAAM,mBAAmB,GAC3B,eAAe,GACf,iBAAiB,GACjB,oBAAoB,GACpB,cAAc,GACd,aAAa,GACb,aAAa,GACb,uBAAuB,GACvB,wBAAwB,GACxB,gBAAgB,GAChB,mBAAmB,GACnB,eAAe,GACf,kBAAkB,GAClB,kBAAkB,GAClB,cAAc,GACd,eAAe,CAAC;AAEpB,MAAM,WAAW,sBAAsB;IACrC;;;;;OAKG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,yCAAyC;AACzC,MAAM,MAAM,qBAAqB,GAC7B,eAAe,GACf,iBAAiB,GACjB,oBAAoB,GACpB,cAAc,GACd,aAAa,GACb,aAAa,GACb,oBAAoB,GACpB,wBAAwB,GACxB,gBAAgB,GAChB,mBAAmB,GACnB,eAAe,GACf,kBAAkB,GAClB,kBAAkB,GAClB,cAAc,GACd,eAAe,CAAC"}
@@ -44,7 +44,8 @@ export class ProjectsResource {
44
44
  /**
45
45
  * Create a project
46
46
  *
47
- * Creates a Project from a URL or GitHub Definition.
47
+ * Creates a Project from a URL or GitHub Spec.
48
+ * Automatic generation is enabled by default for a saved Project.
48
49
  *
49
50
  * Free includes one saved Project, all selected Targets, and the first 25 operations per Target,
50
51
  * with regeneration, history, delivery pull requests, and previews. Pro supports additional
@@ -54,7 +55,7 @@ export class ProjectsResource {
54
55
  * `POST /projects`
55
56
  */
56
57
  async create(body, params, options) {
57
- return this._core.request({
58
+ return this._core.requestData({
58
59
  method: "POST",
59
60
  path: "/projects",
60
61
  security: [{ "apiKey": [] }],
@@ -78,14 +79,14 @@ export class ProjectsResource {
78
79
  });
79
80
  }
80
81
  /**
81
- * Retrieve a project
82
+ * Get a project
82
83
  *
83
- * Returns the Project's settings and Definition ID. List its Targets separately to retrieve
84
- * Target configuration and Deliveries.
84
+ * Returns the Project's settings and Spec ID. List its Targets separately to retrieve Target
85
+ * configuration and Deliveries.
85
86
  * `GET /projects/{project_id}`
86
87
  */
87
- async retrieve(projectId, options) {
88
- return this._core.request({
88
+ async get(projectId, options) {
89
+ return this._core.requestData({
89
90
  method: "GET",
90
91
  path: `/projects/${encodeURIComponent(String(projectId))}`,
91
92
  security: [{ "apiKey": [] }],
@@ -97,7 +98,7 @@ export class ProjectsResource {
97
98
  "500": InternalServerError,
98
99
  },
99
100
  idempotent: true,
100
- schemaKey: "projects.retrieve",
101
+ schemaKey: "projects.get",
101
102
  options,
102
103
  });
103
104
  }
@@ -112,7 +113,7 @@ export class ProjectsResource {
112
113
  * `DELETE /projects/{project_id}`
113
114
  */
114
115
  async delete(projectId, params, options) {
115
- return this._core.request({
116
+ return this._core.requestData({
116
117
  method: "DELETE",
117
118
  path: `/projects/${encodeURIComponent(String(projectId))}`,
118
119
  security: [{ "apiKey": [] }],
@@ -139,10 +140,12 @@ export class ProjectsResource {
139
140
  *
140
141
  * Omitted fields keep their current values. A supplied config replaces the entire stored object;
141
142
  * null or an empty object clears it.
143
+ * With auto_generate enabled, changing shared config queues a Generation for each Target whose
144
+ * effective config changes. A queued or running Target reuses that Generation.
142
145
  * Omitting If-Match applies the update to the current resource; with If-Match, a stale ETag
143
146
  * returns 412 precondition_failed without saving.
144
147
  *
145
- * A `409 target_busy` means a Target is publishing. Retrieve the Project, wait for publication to
148
+ * A `409 target_busy` means a Target is publishing. Retrieve the Project, wait for publishing to
146
149
  * finish, reconcile your update, and retry.
147
150
  * A `502` response means the Project was saved, but an obsolete release pull request could not be
148
151
  * retired. Retrieve the Project and retry the same update to finish retiring reviews if that
@@ -152,7 +155,7 @@ export class ProjectsResource {
152
155
  * `PATCH /projects/{project_id}`
153
156
  */
154
157
  async update(projectId, body, params, options) {
155
- return this._core.request({
158
+ return this._core.requestData({
156
159
  method: "PATCH",
157
160
  path: `/projects/${encodeURIComponent(String(projectId))}`,
158
161
  security: [{ "apiKey": [] }],
@@ -177,180 +180,27 @@ export class ProjectsResource {
177
180
  options,
178
181
  });
179
182
  }
180
- /**
181
- * Analyze a project's latest Definition Revision
182
- *
183
- * Checks the latest Definition Revision after applying its saved patches. Each finding groups
184
- * affected locations under a stable rule ID. A suggested patch is included only when the
185
- * Definition provides enough information to determine the correction.
186
- * `GET /projects/{project_id}/diagnostics`
187
- */
188
- async retrieveDiagnostics(projectId, options) {
189
- return this._core.request({
190
- method: "GET",
191
- path: `/projects/${encodeURIComponent(String(projectId))}/diagnostics`,
192
- security: [{ "apiKey": [] }],
193
- errors: {
194
- "401": UnauthorizedError,
195
- "403": ForbiddenError,
196
- "404": NotFoundError,
197
- "429": RateLimitedError,
198
- "500": InternalServerError,
199
- },
200
- idempotent: true,
201
- schemaKey: "projects.retrieveDiagnostics",
202
- options,
203
- });
204
- }
205
- /**
206
- * Refresh a project's Diagnostics from its configured source
207
- *
208
- * Fetches the configured source and returns updated Diagnostics. Creates a Definition Revision
209
- * only when the content changes. Does not generate Targets or use a metered generation.
210
- *
211
- * A `Idempotency-Key` UUID is generated per call (stable across retries) unless you pass one.
212
- * `POST /projects/{project_id}/diagnostics`
213
- */
214
- async refreshDiagnostics(projectId, params, options) {
215
- return this._core.request({
216
- method: "POST",
217
- path: `/projects/${encodeURIComponent(String(projectId))}/diagnostics`,
218
- security: [{ "apiKey": [] }],
219
- headers: {
220
- "Idempotency-Key": params?.idempotencyKey === undefined ? undefined : String(params?.idempotencyKey),
221
- },
222
- errors: {
223
- "400": BadRequestError,
224
- "401": UnauthorizedError,
225
- "403": ForbiddenError,
226
- "404": NotFoundError,
227
- "409": ConflictError,
228
- "422": UnprocessableEntityError,
229
- "429": RateLimitedError,
230
- "500": InternalServerError,
231
- },
232
- idempotencyKey: "Idempotency-Key",
233
- schemaKey: "projects.refreshDiagnostics",
234
- options,
235
- });
236
- }
237
- /**
238
- * Apply exact, reviewed diagnostic remediations
239
- *
240
- * Applies reviewed patches from Diagnostics. For a repository source, opens or updates a source
241
- * pull request. For a URL source, saves Definition patches.
242
- *
243
- * Findings that need an API-owner decision return `422`. Read the finding's `authoring_brief` and
244
- * update the source instead.
245
- *
246
- * A `Idempotency-Key` UUID is generated per call (stable across retries) unless you pass one.
247
- * `POST /projects/{project_id}/diagnostics/remediations`
248
- */
249
- async remediateDiagnostics(projectId, body, params, options) {
250
- return this._core.request({
251
- method: "POST",
252
- path: `/projects/${encodeURIComponent(String(projectId))}/diagnostics/remediations`,
253
- security: [{ "apiKey": [] }],
254
- headers: {
255
- "Idempotency-Key": params?.idempotencyKey === undefined ? undefined : String(params?.idempotencyKey),
256
- },
257
- body,
258
- errors: {
259
- "400": BadRequestError,
260
- "401": UnauthorizedError,
261
- "403": ForbiddenError,
262
- "404": NotFoundError,
263
- "409": ConflictError,
264
- "422": UnprocessableEntityError,
265
- "429": RateLimitedError,
266
- "500": InternalServerError,
267
- },
268
- idempotencyKey: "Idempotency-Key",
269
- schemaKey: "projects.remediateDiagnostics",
270
- options,
271
- });
272
- }
273
- /**
274
- * Diagnose a project's repository integrations
275
- *
276
- * Checks repository access, Definition readability, source-approval labels, and required checks.
277
- * Includes the latest webhook delivery so you can investigate missing updates.
278
- * `GET /projects/{project_id}/integration-health`
279
- */
280
- async retrieveIntegrationHealth(projectId, options) {
281
- return this._core.request({
282
- method: "GET",
283
- path: `/projects/${encodeURIComponent(String(projectId))}/integration-health`,
284
- security: [{ "apiKey": [] }],
285
- errors: {
286
- "401": UnauthorizedError,
287
- "403": ForbiddenError,
288
- "404": NotFoundError,
289
- "429": RateLimitedError,
290
- "500": InternalServerError,
291
- },
292
- idempotent: true,
293
- schemaKey: "projects.retrieveIntegrationHealth",
294
- options,
295
- });
296
- }
297
- /**
298
- * List a project's generations
299
- *
300
- * Auto-paginates: `for await (const item of …)` walks every page.
301
- * `GET /projects/{project_id}/generations`
302
- */
303
- listGenerations(projectId, params, options) {
304
- return paginate(this._core, {
305
- method: "GET",
306
- path: `/projects/${encodeURIComponent(String(projectId))}/generations`,
307
- security: [{ "apiKey": [] }],
308
- query: {
309
- limit: params?.limit,
310
- cursor: params?.cursor,
311
- target_id: params?.targetId,
312
- },
313
- errors: {
314
- "400": BadRequestError,
315
- "401": UnauthorizedError,
316
- "403": ForbiddenError,
317
- "404": NotFoundError,
318
- "429": RateLimitedError,
319
- "500": InternalServerError,
320
- },
321
- idempotent: true,
322
- schemaKey: "projects.listGenerations",
323
- options,
324
- }, {
325
- style: "cursor",
326
- itemsField: "data",
327
- cursorParam: "cursor",
328
- nextCursorField: "next_cursor",
329
- hasMoreField: "has_more",
330
- limitParam: "limit",
331
- });
332
- }
333
183
  /**
334
184
  * Start generation for active Targets
335
185
  *
336
186
  * Queues one Generation per active Target and returns their IDs. Retrieve each Generation until
337
- * its status moves from `queued` to `running` and then `succeeded` or `failed`. `succeeded` means
187
+ * its status moves from `queued` to `running` and then `completed` or `failed`. `completed` means
338
188
  * generated files are saved; check Delivery and Draft status separately for repository delivery
339
189
  * and pull requests. A Target already queued or running is returned without starting another
340
190
  * Generation. A matching Idempotency-Key replay returns the same Generations with their current
341
191
  * statuses.
342
192
  *
343
- * If the package already matches a destination and no Draft is open, delivery reports `pr_status:
344
- * no_changes` without creating a commit, branch, or pull request. An existing Draft stays open.
345
- * Automatic generation uses the same workflow.
193
+ * If the package already matches a destination and no Draft is open, delivery creates no commit,
194
+ * branch, or pull request. An existing Draft stays open. Automatic generation uses the same
195
+ * workflow.
346
196
  *
347
197
  * A `Idempotency-Key` UUID is generated per call (stable across retries) unless you pass one.
348
- * `POST /projects/{project_id}/generations`
198
+ * `POST /projects/{project_id}/generate`
349
199
  */
350
200
  async generate(projectId, body, params, options) {
351
- return this._core.request({
201
+ return this._core.requestData({
352
202
  method: "POST",
353
- path: `/projects/${encodeURIComponent(String(projectId))}/generations`,
203
+ path: `/projects/${encodeURIComponent(String(projectId))}/generate`,
354
204
  security: [{ "apiKey": [] }],
355
205
  headers: {
356
206
  "Idempotency-Key": params?.idempotencyKey === undefined ? undefined : String(params?.idempotencyKey),
@@ -0,0 +1,46 @@
1
+ import { HttpCore, type RequestOptions } from "../core/http.js";
2
+ import { PagePromise } from "../core/pagination.js";
3
+ import { ResponseParseError, TransportError, UnexpectedApiError, ValidationError, BadRequestError, ForbiddenError, InternalServerError, NotFoundError, RateLimitedError, UnauthorizedError } from "../errors.js";
4
+ import type { PublicationId, PublicationRead, PublicationResponseRead, ReleaseId } from "../types.js";
5
+ export declare class PublicationsResource {
6
+ private readonly _core;
7
+ constructor(_core: HttpCore);
8
+ /**
9
+ * List publications
10
+ *
11
+ * Auto-paginates: `for await (const item of …)` walks every page.
12
+ * `GET /publications`
13
+ */
14
+ list(params?: PublicationsListParams, options?: RequestOptions): PagePromise<PublicationRead, PublicationsListError>;
15
+ /**
16
+ * Get publishing status
17
+ *
18
+ * Returns the registry publishing status for a release. A status in another organization returns
19
+ * 404 not_found.
20
+ * `GET /publications/{publication_id}`
21
+ */
22
+ get(publicationId: PublicationId, options?: RequestOptions): Promise<PublicationResponseRead>;
23
+ }
24
+ export interface PublicationsListParams {
25
+ /**
26
+ * Maximum number of resources to return. Omit for 20; otherwise supply base-10 digits
27
+ * representing an integer from 1 to 100. Empty, malformed, or out-of-range values return 400
28
+ * invalid_request. List query parameters must appear only once; unrecognized parameters also
29
+ * return 400.
30
+ */
31
+ limit?: number;
32
+ /**
33
+ * Opaque cursor from the preceding page's next_cursor. Valid only for the same organization,
34
+ * operation, filters, and ordering that issued it. Omit to start at the first page. Empty,
35
+ * malformed, or repeated cursors return 400 invalid_request. The page limit may change between
36
+ * requests.
37
+ */
38
+ cursor?: string;
39
+ /** Only publications of this release. */
40
+ releaseId?: ReleaseId;
41
+ }
42
+ /** Typed errors `list` can throw. */
43
+ export type PublicationsListError = BadRequestError | UnauthorizedError | ForbiddenError | NotFoundError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
44
+ /** Typed errors `get` can throw. */
45
+ export type PublicationsGetError = UnauthorizedError | ForbiddenError | NotFoundError | RateLimitedError | InternalServerError | UnexpectedApiError | ResponseParseError | TransportError | ValidationError;
46
+ //# sourceMappingURL=publications.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"publications.d.ts","sourceRoot":"","sources":["../../src/resources/publications.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,QAAQ,EAAE,KAAK,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAChE,OAAO,EAAY,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EACL,kBAAkB,EAClB,cAAc,EACd,kBAAkB,EAClB,eAAe,EACf,eAAe,EACf,cAAc,EACd,mBAAmB,EACnB,aAAa,EACb,gBAAgB,EAChB,iBAAiB,EAClB,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,EAEV,aAAa,EAGb,eAAe,EAEf,uBAAuB,EACvB,SAAS,EACV,MAAM,aAAa,CAAC;AAErB,qBAAa,oBAAoB;IACnB,OAAO,CAAC,QAAQ,CAAC,KAAK;gBAAL,KAAK,EAAE,QAAQ;IAC5C;;;;;OAKG;IACH,IAAI,CACF,MAAM,CAAC,EAAE,sBAAsB,EAC/B,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,eAAe,EAAE,qBAAqB,CAAC;IA+BtD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