@madewithremy/admin 0.1.23 → 0.1.24
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/dist/index.d.ts +68 -39
- package/dist/index.js +40 -7
- package/dist/index.js.map +1 -1
- package/dist/prod.js +174 -60
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -5064,14 +5064,16 @@ declare namespace infra {
|
|
|
5064
5064
|
* youai-api/src/common/Db/v2Apps/V2AppIssuesDao.ts
|
|
5065
5065
|
* youai-api/src/common/Db/v2Apps/V2AppIssueCommentsDao.ts
|
|
5066
5066
|
*/
|
|
5067
|
-
type IssueKind = 'bug' | 'idea' | 'task';
|
|
5068
5067
|
type IssueStatus = 'open' | 'closed';
|
|
5069
5068
|
/**
|
|
5070
|
-
* 'user' = workspace member; 'agent' = Remy agent;
|
|
5071
|
-
* 'system' = server-set activity events; 'sdk' = end-user report.
|
|
5069
|
+
* 'user' = workspace member; 'agent' = Remy agent; 'app' = another app's
|
|
5070
|
+
* backend; 'system' = server-set activity events; 'sdk' = end-user report.
|
|
5071
|
+
*
|
|
5072
|
+
* Authorship is this × `originAppId`: 'agent' with an origin is another app's
|
|
5073
|
+
* agent, 'app' with an origin is its backend, 'agent' alone is the app's own.
|
|
5072
5074
|
*/
|
|
5073
|
-
type IssueAuthorKind = 'user' | 'agent' | 'system' | 'sdk';
|
|
5074
|
-
type IssueEventType = 'closed' | 'reopened'
|
|
5075
|
+
type IssueAuthorKind = 'user' | 'agent' | 'system' | 'sdk' | 'app';
|
|
5076
|
+
type IssueEventType = 'closed' | 'reopened';
|
|
5075
5077
|
/** One issue row (V2AppIssue from V2AppIssuesDao). */
|
|
5076
5078
|
interface IssueRow {
|
|
5077
5079
|
id: string;
|
|
@@ -5080,21 +5082,21 @@ interface IssueRow {
|
|
|
5080
5082
|
number: number;
|
|
5081
5083
|
title: string;
|
|
5082
5084
|
body: string;
|
|
5083
|
-
kind
|
|
5085
|
+
/** Open label set. Replaced the closed bug/idea/task `kind` enum. */
|
|
5086
|
+
labels: string[];
|
|
5084
5087
|
status: IssueStatus;
|
|
5085
5088
|
authorKind: IssueAuthorKind;
|
|
5086
5089
|
authorUserId: string | null;
|
|
5090
|
+
/** The app that filed this, when another app did; null otherwise. */
|
|
5091
|
+
originAppId: string | null;
|
|
5087
5092
|
/** Free-form reporter label for 'sdk'-authored (end-user) reports; null otherwise. */
|
|
5088
5093
|
reporter: string | null;
|
|
5089
5094
|
releaseId: string | null;
|
|
5090
5095
|
commitSha: string | null;
|
|
5091
5096
|
/** Full source blob for error/crash-linked issues (e.g. { kind, key, releaseId }). */
|
|
5092
5097
|
linkedSignal: unknown | null;
|
|
5093
|
-
/** Namespaced grouping key (`<
|
|
5098
|
+
/** Namespaced grouping key (`<sourceKind>:<key>`) used for open-issue dedup. */
|
|
5094
5099
|
sourceKey: string | null;
|
|
5095
|
-
/** Triage enrichment payload; null until enrichmentStatus is 'ready'. */
|
|
5096
|
-
enrichment: unknown | null;
|
|
5097
|
-
enrichmentStatus: string;
|
|
5098
5100
|
createdAt: string;
|
|
5099
5101
|
updatedAt: string;
|
|
5100
5102
|
closedAt: string | null;
|
|
@@ -5113,12 +5115,17 @@ interface IssueCommentRow {
|
|
|
5113
5115
|
body: string;
|
|
5114
5116
|
authorKind: IssueAuthorKind;
|
|
5115
5117
|
authorUserId: string | null;
|
|
5116
|
-
/**
|
|
5118
|
+
/** The app that wrote this entry, when another app did; null otherwise. */
|
|
5119
|
+
originAppId: string | null;
|
|
5120
|
+
/** Free-form blob an agent-authored entry may carry; null otherwise. */
|
|
5117
5121
|
metadata: unknown | null;
|
|
5118
5122
|
createdAt: string;
|
|
5119
5123
|
updatedAt: string;
|
|
5120
5124
|
}
|
|
5121
|
-
/**
|
|
5125
|
+
/**
|
|
5126
|
+
* issues list → GET /_internal/v2/apps/:appId/issues
|
|
5127
|
+
* issues filed → GET /_internal/v2/apps/:appId/issues/filed
|
|
5128
|
+
*/
|
|
5122
5129
|
interface IssuesListResult {
|
|
5123
5130
|
issues: IssueRow[];
|
|
5124
5131
|
/** Opaque keyset cursor; pass as ?cursor= to fetch the next page. */
|
|
@@ -5167,24 +5174,39 @@ interface IssuesDeleteResult {
|
|
|
5167
5174
|
*/
|
|
5168
5175
|
|
|
5169
5176
|
interface IssuesListParams {
|
|
5170
|
-
/** Filter by status: `open` or `closed`. */
|
|
5177
|
+
/** Filter by status: `open` or `closed`. Omit for any state. */
|
|
5171
5178
|
status?: string;
|
|
5172
|
-
/**
|
|
5173
|
-
|
|
5179
|
+
/** Match issues carrying ANY of these labels. */
|
|
5180
|
+
labels?: string[];
|
|
5181
|
+
/** Only issues another app filed here, by that app's id. */
|
|
5182
|
+
originAppId?: string;
|
|
5174
5183
|
/** Max issues to return (default 50). */
|
|
5175
5184
|
limit?: number;
|
|
5176
5185
|
/** Keyset cursor from a previous response's `nextCursor`. */
|
|
5177
5186
|
cursor?: string;
|
|
5178
5187
|
}
|
|
5179
5188
|
/**
|
|
5180
|
-
* List issues newest-first.
|
|
5189
|
+
* List the issues filed IN an app, newest-first.
|
|
5181
5190
|
*
|
|
5182
5191
|
* @throws AdminApiError `invalid_status` (400) — status is not `open` or
|
|
5183
|
-
* `closed
|
|
5192
|
+
* `closed`.
|
|
5184
5193
|
* @example
|
|
5185
|
-
* const { issues } = await admin.issues.list({ status: 'open',
|
|
5194
|
+
* const { issues } = await admin.issues.list({ status: 'open', labels: ['bug'] });
|
|
5186
5195
|
*/
|
|
5187
5196
|
declare function list$5(ctx: AdminContext, params?: IssuesListParams): Promise<IssuesListResult>;
|
|
5197
|
+
/**
|
|
5198
|
+
* List the issues this app filed INTO other apps, newest-first.
|
|
5199
|
+
*
|
|
5200
|
+
* The sender's half of a cross-app thread: one call returns every issue the
|
|
5201
|
+
* app sent out, so a fan-out across forty apps is read once rather than forty
|
|
5202
|
+
* times. Scoped to apps in the same workspace.
|
|
5203
|
+
*
|
|
5204
|
+
* @throws AdminApiError `invalid_status` (400) — status is not `open` or
|
|
5205
|
+
* `closed`.
|
|
5206
|
+
* @example
|
|
5207
|
+
* const { issues } = await admin.issues.filed({ status: 'open' });
|
|
5208
|
+
*/
|
|
5209
|
+
declare function filed(ctx: AdminContext, params?: Omit<IssuesListParams, 'originAppId'>): Promise<IssuesListResult>;
|
|
5188
5210
|
/**
|
|
5189
5211
|
* Get one issue with its full comment thread.
|
|
5190
5212
|
*
|
|
@@ -5201,8 +5223,14 @@ interface IssuesCreateParams {
|
|
|
5201
5223
|
title: string;
|
|
5202
5224
|
/** Issue body in markdown. */
|
|
5203
5225
|
body?: string;
|
|
5204
|
-
/**
|
|
5205
|
-
|
|
5226
|
+
/** Labels to file it under. Open set, at most 20, 64 chars each. */
|
|
5227
|
+
labels?: string[];
|
|
5228
|
+
/**
|
|
5229
|
+
* The app filing this, when it isn't the app the issue lands in. Set it when
|
|
5230
|
+
* targeting another app (`forApp`) so the thread records who wrote — the
|
|
5231
|
+
* recipient's reply comes back as a comment on this same issue.
|
|
5232
|
+
*/
|
|
5233
|
+
originAppId?: string;
|
|
5206
5234
|
}
|
|
5207
5235
|
/**
|
|
5208
5236
|
* File a new issue authored as the agent (`authorKind: "agent"`).
|
|
@@ -5213,9 +5241,10 @@ interface IssuesCreateParams {
|
|
|
5213
5241
|
* not accept `source`, so `deduped` is always absent from op-layer responses.
|
|
5214
5242
|
*
|
|
5215
5243
|
* @throws AdminApiError `missing_title` (400) — title is required or empty;
|
|
5216
|
-
* `
|
|
5244
|
+
* `invalid_labels` (400) — labels are not strings, or exceed the count /
|
|
5245
|
+
* length caps; `invalid_origin_app_id` (400) — originAppId is not an app id.
|
|
5217
5246
|
* @example
|
|
5218
|
-
* const { issue } = await admin.issues.create({ title: 'Checkout 500s on empty cart',
|
|
5247
|
+
* const { issue } = await admin.issues.create({ title: 'Checkout 500s on empty cart', labels: ['bug'] });
|
|
5219
5248
|
*/
|
|
5220
5249
|
declare function create(ctx: AdminContext, params: IssuesCreateParams): Promise<IssuesCreateResult>;
|
|
5221
5250
|
/**
|
|
@@ -5230,17 +5259,20 @@ declare function create(ctx: AdminContext, params: IssuesCreateParams): Promise<
|
|
|
5230
5259
|
*/
|
|
5231
5260
|
declare function comment(ctx: AdminContext, number: string, body: string): Promise<IssuesCommentResult>;
|
|
5232
5261
|
/**
|
|
5233
|
-
* Close an issue.
|
|
5262
|
+
* Close an issue, optionally with a closing comment.
|
|
5234
5263
|
*
|
|
5235
|
-
* Records a `closed` timeline event on the thread
|
|
5264
|
+
* Records a `closed` timeline event on the thread, preceded by the comment
|
|
5265
|
+
* when one is given — so answering and resolving is one call, which is what
|
|
5266
|
+
* replying to an issue another app filed usually amounts to.
|
|
5236
5267
|
*
|
|
5237
5268
|
* @param number The issue number.
|
|
5269
|
+
* @param comment Optional prose posted before the close event.
|
|
5238
5270
|
* @throws AdminApiError `issue_not_found` (404) — no issue with this number
|
|
5239
5271
|
* in this app.
|
|
5240
5272
|
* @example
|
|
5241
|
-
* await admin.issues.close('42');
|
|
5273
|
+
* await admin.issues.close('42', 'Already fixed in v3 — no change needed.');
|
|
5242
5274
|
*/
|
|
5243
|
-
declare function close(ctx: AdminContext, number: string): Promise<IssuesUpdateResult>;
|
|
5275
|
+
declare function close(ctx: AdminContext, number: string, comment?: string): Promise<IssuesUpdateResult>;
|
|
5244
5276
|
/**
|
|
5245
5277
|
* Reopen a closed issue.
|
|
5246
5278
|
*
|
|
@@ -5258,23 +5290,23 @@ interface IssuesEditParams {
|
|
|
5258
5290
|
title?: string;
|
|
5259
5291
|
/** Replace the issue's body. */
|
|
5260
5292
|
body?: string;
|
|
5261
|
-
/**
|
|
5262
|
-
|
|
5293
|
+
/** Replace the issue's labels wholesale (not a merge). */
|
|
5294
|
+
labels?: string[];
|
|
5263
5295
|
/** Change the status to `open` or `closed`. */
|
|
5264
5296
|
status?: string;
|
|
5265
5297
|
}
|
|
5266
5298
|
/**
|
|
5267
|
-
* Edit an issue's title, body,
|
|
5299
|
+
* Edit an issue's title, body, labels, or status.
|
|
5268
5300
|
*
|
|
5269
5301
|
* Status transitions record a `closed` or `reopened` timeline event
|
|
5270
5302
|
* automatically. At least one field must be provided.
|
|
5271
5303
|
*
|
|
5272
5304
|
* @param number The issue number.
|
|
5273
5305
|
* @throws AdminApiError `missing_title` (400) — title was supplied but empty;
|
|
5274
|
-
* `
|
|
5275
|
-
* `invalid_status` (400) — status is not `open` or `closed`;
|
|
5276
|
-
* (400) — no editable field was provided; `issue_not_found`
|
|
5277
|
-
* issue with this number in this app.
|
|
5306
|
+
* `invalid_labels` (400) — labels are not strings, or exceed the count /
|
|
5307
|
+
* length caps; `invalid_status` (400) — status is not `open` or `closed`;
|
|
5308
|
+
* `no_fields` (400) — no editable field was provided; `issue_not_found`
|
|
5309
|
+
* (404) — no issue with this number in this app.
|
|
5278
5310
|
* @example
|
|
5279
5311
|
* await admin.issues.edit('42', { status: 'closed' });
|
|
5280
5312
|
*/
|
|
@@ -5297,9 +5329,10 @@ declare const issues_close: typeof close;
|
|
|
5297
5329
|
declare const issues_comment: typeof comment;
|
|
5298
5330
|
declare const issues_create: typeof create;
|
|
5299
5331
|
declare const issues_edit: typeof edit;
|
|
5332
|
+
declare const issues_filed: typeof filed;
|
|
5300
5333
|
declare const issues_reopen: typeof reopen;
|
|
5301
5334
|
declare namespace issues {
|
|
5302
|
-
export { type issues_IssuesCreateParams as IssuesCreateParams, type issues_IssuesEditParams as IssuesEditParams, type issues_IssuesListParams as IssuesListParams, issues_close as close, issues_comment as comment, issues_create as create, del$1 as del, issues_edit as edit, get$3 as get, list$5 as list, issues_reopen as reopen };
|
|
5335
|
+
export { type issues_IssuesCreateParams as IssuesCreateParams, type issues_IssuesEditParams as IssuesEditParams, type issues_IssuesListParams as IssuesListParams, issues_close as close, issues_comment as comment, issues_create as create, del$1 as del, issues_edit as edit, issues_filed as filed, get$3 as get, list$5 as list, issues_reopen as reopen };
|
|
5303
5336
|
}
|
|
5304
5337
|
|
|
5305
5338
|
/**
|
|
@@ -6914,10 +6947,6 @@ interface V2AppSettings {
|
|
|
6914
6947
|
* (e.g. 'https://app.acme.com'). Capped at 25 entries.
|
|
6915
6948
|
*/
|
|
6916
6949
|
additionalFrameAncestors?: string[];
|
|
6917
|
-
/**
|
|
6918
|
-
* When true, auto-run the read-only triage agent on new bug issues. Default false.
|
|
6919
|
-
*/
|
|
6920
|
-
autoTriageIssues?: boolean;
|
|
6921
6950
|
}
|
|
6922
6951
|
/**
|
|
6923
6952
|
* Response from GET /_internal/v2/apps/:appId/settings/v2 and
|
|
@@ -7591,4 +7620,4 @@ declare class AdminTimeoutError extends Error {
|
|
|
7591
7620
|
|
|
7592
7621
|
declare const admin: AdminClient;
|
|
7593
7622
|
|
|
7594
|
-
export { AdminApiError, type AdminClient, type AdminClientOptions, type AdminContext, AdminTimeoutError, type AgentThreadDetail, type AgentThreadListItem, type AgentThreadsGetResult, type AgentThreadsListResult, type AgentToolCall, type AgentTranscriptMessage, type AgentTurnError, type AnalyticsAiHostRow, type AnalyticsAiSourcesResult, type AnalyticsAiVendorRow, type AnalyticsBatchResult, type AnalyticsCrawlersOverviewResult, type AnalyticsCrawlersRecentResult, type AnalyticsCrawlersRecentRow, type AnalyticsCrawlersResult, type AnalyticsCrawlersTimeseriesBucket, type AnalyticsCrawlersTimeseriesResult, type AnalyticsLiveResult, type AnalyticsMapPoint, type AnalyticsMapResult, type AnalyticsMetric, type AnalyticsQueryResult, type AnalyticsQueryResultRow, type AnalyticsSourceRow, type AnalyticsSourcesResult, type AppCronJobStatus, type AppCronJobStatusReason, type AppCronRunState, type AppEmailSuppression, type AppSecretRow, type CrashGroup, type CrashOccurrenceRow, type CrashesGetResult, type CrashesListResult, type CrashesOccurrencesResult, type CrashesStatsBucket, type CrashesStatsResult, type CronJobDecorated, type CronOverviewResult, type CronRunResult, type CronRunSummary, type DashboardLiveRelease, type DashboardReleaseMethod, type DashboardResult, type DataLiftFromDevResult, type DataLiftFromLiveResult, type DataSourceConnector, type DataSourceConnectorCredentials, type DataSourceConnectorDeletions, type DataSourceConnectorGetResult, type DataSourceConnectorPolicy, type DataSourceConnectorResult, type DataSourceInspectReport, type DataSourceInspectResult, type DataSourceJob, type DataSourceJobGetResult, type DataSourceJobManifestTokenResult, type DataSourceJobPlan, type DataSourceJobResult, type DataSourceJobSource, type DataSourceJobState, type DataSourceJobsListResult, type DataSourceMapDeployResult, type DataSourceMapTestDocument, type DataSourceMapTestOutcome, type DataSourceMapTestResult, type DataSourceMapper, type DataSourceObjectSelection, type DataSourceQuarantineResult, type DataSourceQuarantinedObject, type DataSourceRemapResult, type DataSourceSyncResult, type DataSourcesBuildProgress, type DataSourcesChunkingConfig, type DataSourcesChunkingStrategy, type DataSourcesConfigResult, type DataSourcesConfigUpdateResult, type DataSourcesCountResult, type DataSourcesCreateResult, type DataSourcesDeleteResult, type DataSourcesDocument, type DataSourcesDocumentConfirmResult, type DataSourcesDocumentDeleteManyResult, type DataSourcesDocumentDeleteResult, type DataSourcesDocumentSelector, type DataSourcesDocumentStatus, type DataSourcesDocumentsResult, type DataSourcesDropResult, type DataSourcesHydrateResult, type DataSourcesHydration, type DataSourcesIndex, type DataSourcesIngestConfig, type DataSourcesIngestUpdate, type DataSourcesListEntry, type DataSourcesListResult, type DataSourcesMigration, type DataSourcesMoveResult, type DataSourcesPlacement, type DataSourcesPromoteResult, type DataSourcesRetrievalConfig, type DataSourcesRetrievalUpdate, type DataSourcesRevectorizeResult, type DataSourcesSampleResult, type DataSourcesSearchCitation, type DataSourcesSearchResult, type DataSourcesSearchResultItem, type DataSourcesUploadTokenResult, type DatasetFile, type DbQueryResult, type DiagnosticsAuditEnvironment, type DiagnosticsDashboardResult, type DiagnosticsFinding, type DiagnosticsLighthouseScores, type DiagnosticsPayload, type DiagnosticsReleaseResult, type DiagnosticsRuntimeFindings, type DomainsCheckResult, type DomainsCustomAddResult, type DomainsCustomCheckResult, type DomainsCustomHostnameUiStatus, type DomainsCustomHostnameView, type DomainsCustomListResult, type DomainsCustomRemoveResult, type DomainsCustomRetryResult, type DomainsDnsInstructions, type DomainsGetResult, type DomainsSetResult, type EmailBatchLifecycle, type EmailBatchResult, type EmailBatchSummary, type EmailBatchesResult, type EmailDomainBase, type EmailEffectiveSender, type EmailInboxResult, type EmailListResult, type EmailMessageKind, type EmailMessageResult, type EmailMessageStatus, type EmailSenderTier, type EmailSendingStatusResult, type EmailStatsResult, type EmailSummary, type EmailSuppressResult, type EmailSuppressionsResult, type EmailUnsuppressResult, type EvalAggregates, type EvalCompareResult, type EvalExpectation, type EvalQueriesAddResult, type EvalQueriesListResult, type EvalQuery, type EvalQueryResult, type EvalQueryStyle, type EvalRetrieval, type EvalRun, type EvalRunResult, type EvalRunState, type EvalRunsListResult, type EvalSet, type EvalSetGetResult, type EvalSetResult, type EvalSetState, type EvalSetsListResult, type EventChannelActivity, type EventsChannelsListResult, type EventsPublishResult, type EventsTailFrame, type FilesDeleteResult, type FilesFileMeta, type FilesListEntry, type FilesListResult, type FilesLsResult, type FilesScanBadge, type FilesScanFlagged, type FilesScanStore, type FilesStatResult, type FilesStoreSummaryEntry, type FilesUploadUrlResult, type FilesUrlResult, type FrontendErrorType, type InboundDnsInstructions, type InboundEmailDomainAddResult, type InboundEmailDomainCheckResult, type InboundEmailDomainDeleteResult, type InboundEmailDomainUiStatus, type InboundEmailDomainVerifyResult, type InboundEmailDomainView, type InboundEmailDomainsListResult, type InboxEmailPreview, type IssueAuthorKind, type IssueCommentRow, type IssueEventType, type
|
|
7623
|
+
export { AdminApiError, type AdminClient, type AdminClientOptions, type AdminContext, AdminTimeoutError, type AgentThreadDetail, type AgentThreadListItem, type AgentThreadsGetResult, type AgentThreadsListResult, type AgentToolCall, type AgentTranscriptMessage, type AgentTurnError, type AnalyticsAiHostRow, type AnalyticsAiSourcesResult, type AnalyticsAiVendorRow, type AnalyticsBatchResult, type AnalyticsCrawlersOverviewResult, type AnalyticsCrawlersRecentResult, type AnalyticsCrawlersRecentRow, type AnalyticsCrawlersResult, type AnalyticsCrawlersTimeseriesBucket, type AnalyticsCrawlersTimeseriesResult, type AnalyticsLiveResult, type AnalyticsMapPoint, type AnalyticsMapResult, type AnalyticsMetric, type AnalyticsQueryResult, type AnalyticsQueryResultRow, type AnalyticsSourceRow, type AnalyticsSourcesResult, type AppCronJobStatus, type AppCronJobStatusReason, type AppCronRunState, type AppEmailSuppression, type AppSecretRow, type CrashGroup, type CrashOccurrenceRow, type CrashesGetResult, type CrashesListResult, type CrashesOccurrencesResult, type CrashesStatsBucket, type CrashesStatsResult, type CronJobDecorated, type CronOverviewResult, type CronRunResult, type CronRunSummary, type DashboardLiveRelease, type DashboardReleaseMethod, type DashboardResult, type DataLiftFromDevResult, type DataLiftFromLiveResult, type DataSourceConnector, type DataSourceConnectorCredentials, type DataSourceConnectorDeletions, type DataSourceConnectorGetResult, type DataSourceConnectorPolicy, type DataSourceConnectorResult, type DataSourceInspectReport, type DataSourceInspectResult, type DataSourceJob, type DataSourceJobGetResult, type DataSourceJobManifestTokenResult, type DataSourceJobPlan, type DataSourceJobResult, type DataSourceJobSource, type DataSourceJobState, type DataSourceJobsListResult, type DataSourceMapDeployResult, type DataSourceMapTestDocument, type DataSourceMapTestOutcome, type DataSourceMapTestResult, type DataSourceMapper, type DataSourceObjectSelection, type DataSourceQuarantineResult, type DataSourceQuarantinedObject, type DataSourceRemapResult, type DataSourceSyncResult, type DataSourcesBuildProgress, type DataSourcesChunkingConfig, type DataSourcesChunkingStrategy, type DataSourcesConfigResult, type DataSourcesConfigUpdateResult, type DataSourcesCountResult, type DataSourcesCreateResult, type DataSourcesDeleteResult, type DataSourcesDocument, type DataSourcesDocumentConfirmResult, type DataSourcesDocumentDeleteManyResult, type DataSourcesDocumentDeleteResult, type DataSourcesDocumentSelector, type DataSourcesDocumentStatus, type DataSourcesDocumentsResult, type DataSourcesDropResult, type DataSourcesHydrateResult, type DataSourcesHydration, type DataSourcesIndex, type DataSourcesIngestConfig, type DataSourcesIngestUpdate, type DataSourcesListEntry, type DataSourcesListResult, type DataSourcesMigration, type DataSourcesMoveResult, type DataSourcesPlacement, type DataSourcesPromoteResult, type DataSourcesRetrievalConfig, type DataSourcesRetrievalUpdate, type DataSourcesRevectorizeResult, type DataSourcesSampleResult, type DataSourcesSearchCitation, type DataSourcesSearchResult, type DataSourcesSearchResultItem, type DataSourcesUploadTokenResult, type DatasetFile, type DbQueryResult, type DiagnosticsAuditEnvironment, type DiagnosticsDashboardResult, type DiagnosticsFinding, type DiagnosticsLighthouseScores, type DiagnosticsPayload, type DiagnosticsReleaseResult, type DiagnosticsRuntimeFindings, type DomainsCheckResult, type DomainsCustomAddResult, type DomainsCustomCheckResult, type DomainsCustomHostnameUiStatus, type DomainsCustomHostnameView, type DomainsCustomListResult, type DomainsCustomRemoveResult, type DomainsCustomRetryResult, type DomainsDnsInstructions, type DomainsGetResult, type DomainsSetResult, type EmailBatchLifecycle, type EmailBatchResult, type EmailBatchSummary, type EmailBatchesResult, type EmailDomainBase, type EmailEffectiveSender, type EmailInboxResult, type EmailListResult, type EmailMessageKind, type EmailMessageResult, type EmailMessageStatus, type EmailSenderTier, type EmailSendingStatusResult, type EmailStatsResult, type EmailSummary, type EmailSuppressResult, type EmailSuppressionsResult, type EmailUnsuppressResult, type EvalAggregates, type EvalCompareResult, type EvalExpectation, type EvalQueriesAddResult, type EvalQueriesListResult, type EvalQuery, type EvalQueryResult, type EvalQueryStyle, type EvalRetrieval, type EvalRun, type EvalRunResult, type EvalRunState, type EvalRunsListResult, type EvalSet, type EvalSetGetResult, type EvalSetResult, type EvalSetState, type EvalSetsListResult, type EventChannelActivity, type EventsChannelsListResult, type EventsPublishResult, type EventsTailFrame, type FilesDeleteResult, type FilesFileMeta, type FilesListEntry, type FilesListResult, type FilesLsResult, type FilesScanBadge, type FilesScanFlagged, type FilesScanStore, type FilesStatResult, type FilesStoreSummaryEntry, type FilesUploadUrlResult, type FilesUrlResult, type FrontendErrorType, type InboundDnsInstructions, type InboundEmailDomainAddResult, type InboundEmailDomainCheckResult, type InboundEmailDomainDeleteResult, type InboundEmailDomainUiStatus, type InboundEmailDomainVerifyResult, type InboundEmailDomainView, type InboundEmailDomainsListResult, type InboxEmailPreview, type IssueAuthorKind, type IssueCommentRow, type IssueEventType, type IssueRow, type IssueStatus, type IssuesCommentResult, type IssuesCreateResult, type IssuesDeleteResult, type IssuesGetResult, type IssuesListResult, type IssuesUpdateResult, type JewelPairRow, type JewelPairSummaryRow, type JewelVerdict, type JewelsDatasetSummary, type JewelsDryrunResult, type JewelsExportResult, type JewelsGradeResult, type JewelsGrading, type JewelsOverviewResult, type JewelsPairResult, type JewelsPairsResult, type JewelsQueueResult, type JewelsResolveResult, type JewelsRunResult, type JewelsRunsResult, type JewelsTimeseriesBucket, type JewelsTimeseriesResult, type JewelsTrainResult, type LiftedDatabase, type MethodsInvokeResult, type OperationProgress, type OutboundDnsInstructions, type OutboundEmailDomainAddResult, type OutboundEmailDomainCheckResult, type OutboundEmailDomainDeleteResult, type OutboundEmailDomainUiStatus, type OutboundEmailDomainVerifyResult, type OutboundEmailDomainView, type OutboundEmailDomainsListResult, type PlatformSuppression, type PrerenderGetResult, type PrerenderInvalidateResult, type PrerenderPage, type PrerenderPagesResult, type PrerenderViewResult, type ReleaseFailureFields, type ReleaseFragment, type ReleasesByCommitResult, type ReleasesGetResult, type ReleasesListResult, type RequestsGetResult, type RequestsListResult, type RequestsListRow, type RequestsStatsMethodBucket, type RequestsStatsMethodResult, type RequestsStatsSummaryBucket, type RequestsStatsSummaryResult, type SecretsDeleteResult, type SecretsGetResult, type SecretsListResult, type SecretsSetResult, type SettingsResult, type SuppressionSource, type TrainingLogEntry, type TrainingRunRow, type TrainingRunStatus, type UserAuthProvider, type UserListItem, type UserRecord, type UsersCreateApiKeyResult, type UsersListResult, type UsersRevokeApiKeyResult, type UsersSetRoleResult, type V2AppSettings, type V2BuildLogEntry, type V2BuildStats, type V2CommitInfo, type V2EmailMessage, type V2ReleaseStatus, type VoiceAvailableNumber, type VoiceNumbersBuyResult, type VoiceNumbersListResult, type VoiceNumbersReleaseResult, type VoiceNumbersSearchResult, type VoiceNumbersSetNameResult, type VoicePhoneNumberStatus, type VoicePhoneNumberView, type VoiceResolvedPolicy, type VoiceSessionChannel, type VoiceSessionCost, type VoiceSessionCostLine, type VoiceSessionDetail, type VoiceSessionGetResult, type VoiceSessionListItem, type VoiceSessionSip, type VoiceSessionSpeechEntry, type VoiceSessionStatus, type VoiceSessionToolEntry, type VoiceSessionTranscriptEntry, type VoiceSessionsListResult, type VoiceSettingsCeilings, type VoiceSettingsGetResult, type VoiceSettingsOverrides, type VoiceSettingsSetResult, admin, createAdminClient, admin as default };
|
package/dist/index.js
CHANGED
|
@@ -109,6 +109,12 @@ function qs(params) {
|
|
|
109
109
|
if (value === void 0 || value === null) {
|
|
110
110
|
continue;
|
|
111
111
|
}
|
|
112
|
+
if (Array.isArray(value)) {
|
|
113
|
+
for (const entry of value) {
|
|
114
|
+
search2.append(key, String(entry));
|
|
115
|
+
}
|
|
116
|
+
continue;
|
|
117
|
+
}
|
|
112
118
|
search2.set(key, String(value));
|
|
113
119
|
}
|
|
114
120
|
const text = search2.toString();
|
|
@@ -2105,15 +2111,32 @@ __export(issues_exports, {
|
|
|
2105
2111
|
create: () => create2,
|
|
2106
2112
|
del: () => del,
|
|
2107
2113
|
edit: () => edit,
|
|
2114
|
+
filed: () => filed,
|
|
2108
2115
|
get: () => get8,
|
|
2109
2116
|
list: () => list8,
|
|
2110
2117
|
reopen: () => reopen
|
|
2111
2118
|
});
|
|
2119
|
+
function listQuery(params) {
|
|
2120
|
+
return qs({
|
|
2121
|
+
status: params.status,
|
|
2122
|
+
label: params.labels,
|
|
2123
|
+
originAppId: params.originAppId,
|
|
2124
|
+
limit: params.limit,
|
|
2125
|
+
cursor: params.cursor
|
|
2126
|
+
});
|
|
2127
|
+
}
|
|
2112
2128
|
function list8(ctx, params = {}) {
|
|
2113
2129
|
return call(
|
|
2114
2130
|
ctx,
|
|
2115
2131
|
"GET",
|
|
2116
|
-
`/_internal/v2/apps/${ctx.appId}/issues${
|
|
2132
|
+
`/_internal/v2/apps/${ctx.appId}/issues${listQuery(params)}`
|
|
2133
|
+
);
|
|
2134
|
+
}
|
|
2135
|
+
function filed(ctx, params = {}) {
|
|
2136
|
+
return call(
|
|
2137
|
+
ctx,
|
|
2138
|
+
"GET",
|
|
2139
|
+
`/_internal/v2/apps/${ctx.appId}/issues/filed${listQuery(params)}`
|
|
2117
2140
|
);
|
|
2118
2141
|
}
|
|
2119
2142
|
function get8(ctx, number) {
|
|
@@ -2131,8 +2154,11 @@ function create2(ctx, params) {
|
|
|
2131
2154
|
if (params.body !== void 0) {
|
|
2132
2155
|
requestBody.body = params.body;
|
|
2133
2156
|
}
|
|
2134
|
-
if (params.
|
|
2135
|
-
requestBody.
|
|
2157
|
+
if (params.labels !== void 0) {
|
|
2158
|
+
requestBody.labels = params.labels;
|
|
2159
|
+
}
|
|
2160
|
+
if (params.originAppId !== void 0) {
|
|
2161
|
+
requestBody.originAppId = params.originAppId;
|
|
2136
2162
|
}
|
|
2137
2163
|
return call(
|
|
2138
2164
|
ctx,
|
|
@@ -2149,12 +2175,19 @@ function comment(ctx, number, body) {
|
|
|
2149
2175
|
{ body, authorKind: "agent" }
|
|
2150
2176
|
);
|
|
2151
2177
|
}
|
|
2152
|
-
function close(ctx, number) {
|
|
2178
|
+
function close(ctx, number, comment2) {
|
|
2179
|
+
const requestBody = {
|
|
2180
|
+
status: "closed",
|
|
2181
|
+
authorKind: "agent"
|
|
2182
|
+
};
|
|
2183
|
+
if (comment2 !== void 0) {
|
|
2184
|
+
requestBody.comment = comment2;
|
|
2185
|
+
}
|
|
2153
2186
|
return call(
|
|
2154
2187
|
ctx,
|
|
2155
2188
|
"POST",
|
|
2156
2189
|
`/_internal/v2/apps/${ctx.appId}/issues/${seg(number)}/update`,
|
|
2157
|
-
|
|
2190
|
+
requestBody
|
|
2158
2191
|
);
|
|
2159
2192
|
}
|
|
2160
2193
|
function reopen(ctx, number) {
|
|
@@ -2173,8 +2206,8 @@ function edit(ctx, number, params) {
|
|
|
2173
2206
|
if (params.body !== void 0) {
|
|
2174
2207
|
requestBody.body = params.body;
|
|
2175
2208
|
}
|
|
2176
|
-
if (params.
|
|
2177
|
-
requestBody.
|
|
2209
|
+
if (params.labels !== void 0) {
|
|
2210
|
+
requestBody.labels = params.labels;
|
|
2178
2211
|
}
|
|
2179
2212
|
if (params.status !== void 0) {
|
|
2180
2213
|
requestBody.status = params.status;
|