@bedrock-rbx/ocale 0.3.4-beta.1 → 0.4.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/README.md +9 -5
- package/dist/badge-cost-mismatch-DrlvhlQc.mjs +47 -0
- package/dist/badge-cost-mismatch-DrlvhlQc.mjs.map +1 -0
- package/dist/badges.d.mts +228 -184
- package/dist/badges.d.mts.map +1 -1
- package/dist/badges.mjs +176 -18
- package/dist/badges.mjs.map +1 -1
- package/dist/capacity-admission-hycCFkTo.d.mts +355 -0
- package/dist/capacity-admission-hycCFkTo.d.mts.map +1 -0
- package/dist/{data.generated-B2ceLfSn.d.mts → data.generated-D_vpa5-g.d.mts} +23 -23
- package/dist/data.generated-D_vpa5-g.d.mts.map +1 -0
- package/dist/developer-products.d.mts +181 -186
- package/dist/developer-products.d.mts.map +1 -1
- package/dist/developer-products.mjs +24 -24
- package/dist/developer-products.mjs.map +1 -1
- package/dist/game-passes.d.mts +206 -203
- package/dist/game-passes.d.mts.map +1 -1
- package/dist/game-passes.mjs +26 -21
- package/dist/game-passes.mjs.map +1 -1
- package/dist/index.d.mts +924 -306
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +325 -10
- package/dist/index.mjs.map +1 -1
- package/dist/locales.d.mts +30 -2
- package/dist/locales.d.mts.map +1 -0
- package/dist/locales.mjs +24 -1
- package/dist/locales.mjs.map +1 -1
- package/dist/luau-execution.d.mts +154 -151
- package/dist/luau-execution.d.mts.map +1 -1
- package/dist/luau-execution.mjs +11 -8
- package/dist/luau-execution.mjs.map +1 -1
- package/dist/{network-error-DR9FX5hb.mjs → network-error-iVSng5MT.mjs} +44 -6
- package/dist/network-error-iVSng5MT.mjs.map +1 -0
- package/dist/places.d.mts +204 -180
- package/dist/places.d.mts.map +1 -1
- package/dist/places.mjs +66 -20
- package/dist/places.mjs.map +1 -1
- package/dist/{poll-timeout-3PXLsabj.mjs → poll-timeout-DzztDymd.mjs} +2 -2
- package/dist/{poll-timeout-3PXLsabj.mjs.map → poll-timeout-DzztDymd.mjs.map} +1 -1
- package/dist/{polling-helpers-sKTsqEc1.mjs → polling-helpers-DfF5dspc.mjs} +249 -83
- package/dist/polling-helpers-DfF5dspc.mjs.map +1 -0
- package/dist/{price-information-hWXV6DAI.mjs → price-information-DEkEQ8Pq.mjs} +2 -2
- package/dist/{price-information-hWXV6DAI.mjs.map → price-information-DEkEQ8Pq.mjs.map} +1 -1
- package/dist/resource-client-BCKukheG.d.mts +168 -0
- package/dist/resource-client-BCKukheG.d.mts.map +1 -0
- package/dist/resource-client-CaIVr-go.mjs +1419 -0
- package/dist/resource-client-CaIVr-go.mjs.map +1 -0
- package/dist/retry-C2oHesDx.d.mts +229 -0
- package/dist/retry-C2oHesDx.d.mts.map +1 -0
- package/dist/{retry-vpHMIwaU.mjs → retry-CMRDvAR4.mjs} +390 -20
- package/dist/retry-CMRDvAR4.mjs.map +1 -0
- package/dist/storage.d.mts +333 -334
- package/dist/storage.d.mts.map +1 -1
- package/dist/storage.mjs +29 -22
- package/dist/storage.mjs.map +1 -1
- package/dist/testing.d.mts +347 -360
- package/dist/testing.d.mts.map +1 -1
- package/dist/testing.mjs +3 -4
- package/dist/testing.mjs.map +1 -1
- package/dist/types-CdMr_J1M.d.mts +509 -0
- package/dist/types-CdMr_J1M.d.mts.map +1 -0
- package/dist/universes.d.mts +619 -422
- package/dist/universes.d.mts.map +1 -1
- package/dist/universes.mjs +421 -48
- package/dist/universes.mjs.map +1 -1
- package/dist/{validation-B_Zs1So2.mjs → validation-964VNlbp.mjs} +2 -2
- package/dist/{validation-B_Zs1So2.mjs.map → validation-964VNlbp.mjs.map} +1 -1
- package/dist/wire-DJqupefn.d.mts +41 -0
- package/dist/wire-DJqupefn.d.mts.map +1 -0
- package/package.json +14 -14
- package/dist/capacity-admission-BvnJjY0S.d.mts +0 -369
- package/dist/capacity-admission-BvnJjY0S.d.mts.map +0 -1
- package/dist/data.generated-B2ceLfSn.d.mts.map +0 -1
- package/dist/network-error-DR9FX5hb.mjs.map +0 -1
- package/dist/polling-helpers-sKTsqEc1.mjs.map +0 -1
- package/dist/resource-client-3cOhqZpX.mjs +0 -899
- package/dist/resource-client-3cOhqZpX.mjs.map +0 -1
- package/dist/resource-client-BivRq3JZ.d.mts +0 -164
- package/dist/resource-client-BivRq3JZ.d.mts.map +0 -1
- package/dist/retry-DXEklFrt.d.mts +0 -373
- package/dist/retry-DXEklFrt.d.mts.map +0 -1
- package/dist/retry-vpHMIwaU.mjs.map +0 -1
- package/dist/types-C3Egi37J.d.mts +0 -378
- package/dist/types-C3Egi37J.d.mts.map +0 -1
- package/dist/wire-D3K-a-UP.d.mts +0 -37
- package/dist/wire-D3K-a-UP.d.mts.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"network-error-iVSng5MT.mjs","names":[],"sources":["../src/errors/base.ts","../src/errors/api-error.ts","../src/errors/rate-limit.ts","../src/errors/network-error.ts"],"sourcesContent":["/**\n * Options for constructing an {@link OpenCloudError}.\n *\n * @since 0.3.0\n */\nexport interface OpenCloudErrorOptions extends ErrorOptions {\n\t/**\n\t * Machine-readable classifier for the failure, when the error has one. An\n\t * `ApiError` and `RateLimitError` fill it from the response body; a\n\t * `ValidationError` narrows it to its own closed union. Errors with nothing\n\t * to classify (transport failures and poll timeouts) leave it `undefined`.\n\t */\n\treadonly code?: string | undefined;\n}\n\nconst NO_PREVIOUS_ATTEMPTS: ReadonlyArray<OpenCloudError> = Object.freeze([]);\n\nconst PREVIOUS_ATTEMPTS = new WeakMap<OpenCloudError, ReadonlyArray<OpenCloudError>>();\n\n/**\n * Base error class for all Open Cloud SDK errors.\n *\n * All specific error types (RateLimitError, ApiError, NetworkError)\n * extend this class, enabling `instanceof OpenCloudError` checks.\n *\n * `code` is declared here rather than on the subclasses that populate it, so a\n * caller holding the `OpenCloudError` that `Result.err` is typed as can branch\n * on it without first narrowing to a subclass.\n *\n * @since 0.1.0\n *\n * @example\n *\n * ```ts\n * import { ApiError, OpenCloudError } from \"@bedrock-rbx/ocale\";\n *\n * // `Result.err` is typed as OpenCloudError, so a caller draining a queue\n * // branches on the canonical status without narrowing to a subclass first.\n * const err: OpenCloudError = new ApiError(\"HTTP 404: Queue items not found.\", {\n * code: \"NOT_FOUND\",\n * statusCode: 404,\n * });\n *\n * expect(err.code).toBe(\"NOT_FOUND\");\n * expect(new OpenCloudError(\"no classifier\").code).toBeUndefined();\n * ```\n */\nexport class OpenCloudError extends Error {\n\t/** Machine-readable classifier, or `undefined` when the error has none. */\n\tpublic readonly code: string | undefined;\n\tpublic override readonly name: string = \"OpenCloudError\";\n\n\t/**\n\t * Creates a new OpenCloudError.\n\t *\n\t * @param message - Human-readable error description.\n\t * @param options - Error options including the optional `cause` and the\n\t * machine-readable `code`.\n\t */\n\tconstructor(message?: string, options?: OpenCloudErrorOptions) {\n\t\tsuper(message, options);\n\t\tthis.code = options?.code;\n\t}\n\n\t/**\n\t * Failures of the earlier attempts of the same logical request, oldest\n\t * first. A failure that is this error's own `cause` is not repeated here.\n\t * Empty when the request was not retried.\n\t *\n\t * @since 0.4.0\n\t * @returns The earlier attempts' failures.\n\t */\n\tpublic get previousAttempts(): ReadonlyArray<OpenCloudError> {\n\t\treturn PREVIOUS_ATTEMPTS.get(this) ?? NO_PREVIOUS_ATTEMPTS;\n\t}\n}\n\n/**\n * Records the failures of the earlier attempts of the logical request that\n * produced `error`, so they read back through\n * {@link OpenCloudError.previousAttempts}.\n *\n * @param error - The failure the retry loop returns.\n * @param attempts - Earlier attempt failures, oldest first.\n * @returns The same error.\n */\nexport function recordPreviousAttempts(\n\terror: OpenCloudError,\n\tattempts: ReadonlyArray<OpenCloudError>,\n): OpenCloudError {\n\tPREVIOUS_ATTEMPTS.set(error, Object.freeze([...attempts]));\n\treturn error;\n}\n","import { OpenCloudError, type OpenCloudErrorOptions } from \"./base.ts\";\n\n/**\n * Options for constructing an {@link ApiError}.\n *\n * @since 0.1.0\n */\nexport interface ApiErrorOptions extends OpenCloudErrorOptions {\n\t/** Parsed response body, when present. */\n\tdetails?: JSONValue | undefined;\n\t/**\n\t * Wall-clock time the request was in flight before this error, in\n\t * milliseconds. Present for errors built by the transport; a long elapsed\n\t * time on an intermittent failure points at a load or timeout correlation.\n\t */\n\telapsedMs?: number | undefined;\n\t/**\n\t * Human-readable summary extracted from an HTML gateway error page, set\n\t * when the error body was such a page (an HAProxy-style load-balancer\n\t * rejection) rather than an Open Cloud response. When present, the raw HTML\n\t * is not retained on {@link ApiError.details}.\n\t */\n\tgatewaySummary?: string | undefined;\n\t/** HTTP method of the request that produced this error. */\n\tmethod?: string | undefined;\n\t/**\n\t * Allowlisted response headers useful for diagnosis and escalation (request\n\t * ids, edge/server identifiers). The full header set is never retained, to\n\t * avoid surfacing anything sensitive and to keep errors light.\n\t */\n\tresponseHeaders?: Readonly<Record<string, string>> | undefined;\n\t/** HTTP status code from the API response. */\n\tstatusCode: number;\n\t/**\n\t * Length, in decoded characters, of a 2xx body that could not be parsed as\n\t * JSON. Set only by the transport, and only for that failure — nothing else\n\t * builds an {@link ApiError} over a successful status — so its presence is\n\t * also how a body-parse failure is told apart from an API rejection. The\n\t * number is the diagnostic one: a body that stops mid-token at exactly the\n\t * length the edge delivered is a truncated read, not malformed JSON.\n\t */\n\tunparsedBodyLength?: number | undefined;\n\t/** Fully-qualified URL of the request that produced this error. */\n\turl?: string | undefined;\n}\n\n/**\n * Everything in {@link ApiErrorOptions} except what the API answered ({@link\n * ApiErrorOptions.code}, {@link ApiErrorOptions.details}, and {@link\n * ApiErrorOptions.statusCode}): the request the transport made, how long it was\n * in flight, and what the response carried alongside its body. Every field is\n * required, and every one accepts `undefined` for a field the transport did not\n * capture.\n *\n * @since 0.2.0\n */\nexport type ApiRequestContext = {\n\t[K in Exclude<keyof ApiErrorOptions, \"cause\" | \"code\" | \"details\" | \"statusCode\">]-?:\n\t\t| ApiErrorOptions[K]\n\t\t| undefined;\n};\n\n/**\n * Thrown when the Roblox Open Cloud API returns a non-2xx response\n * that is not a rate limit (429).\n *\n * @since 0.1.0\n *\n * @example\n *\n * ```ts\n * import { ApiError } from \"@bedrock-rbx/ocale\";\n *\n * const error = new ApiError(\"HTTP 404: Pass not found (code NotFound)\", {\n * code: \"NotFound\",\n * details: { errorCode: \"NotFound\", message: \"Pass not found\" },\n * statusCode: 404,\n * });\n *\n * expect(error).toBeInstanceOf(ApiError);\n * expect(error.statusCode).toBe(404);\n * expect(error.code).toBe(\"NotFound\");\n * expect(error.details).toEqual({\n * errorCode: \"NotFound\",\n * message: \"Pass not found\",\n * });\n * ```\n */\nexport class ApiError extends OpenCloudError {\n\tpublic readonly details: JSONValue | undefined;\n\tpublic readonly elapsedMs: number | undefined;\n\tpublic readonly gatewaySummary: string | undefined;\n\tpublic readonly method: string | undefined;\n\tpublic override readonly name: string = \"ApiError\";\n\tpublic readonly responseHeaders: Readonly<Record<string, string>> | undefined;\n\tpublic readonly statusCode: number;\n\tpublic readonly unparsedBodyLength: number | undefined;\n\tpublic readonly url: string | undefined;\n\n\t/**\n\t * Creates a new ApiError.\n\t *\n\t * @param message - Human-readable error description.\n\t * @param options - Error options including status code, optional error\n\t * code, the parsed response body when present, and the request context\n\t * (method, url, elapsed time, allowlisted response headers) when built by\n\t * the transport.\n\t */\n\tconstructor(message: string, options: ApiErrorOptions) {\n\t\tsuper(message, options);\n\t\tthis.statusCode = options.statusCode;\n\t\tthis.details = options.details;\n\t\tthis.method = options.method;\n\t\tthis.url = options.url;\n\t\tthis.elapsedMs = options.elapsedMs;\n\t\tthis.responseHeaders = options.responseHeaders;\n\t\tthis.gatewaySummary = options.gatewaySummary;\n\t\tthis.unparsedBodyLength = options.unparsedBodyLength;\n\t}\n}\n\n/**\n * Reads the request context off an {@link ApiError} so a replacement error can\n * carry it. Spread the result into the options of the new error. {@link\n * OpenCloudError.code}, {@link ApiError.details}, and {@link\n * ApiError.statusCode} describe the API's answer and are left to the caller.\n *\n * @since 0.2.0\n *\n * @param err - The error to read the request context from.\n * @returns The transport-captured fields, each undefined when unset.\n *\n * @example\n *\n * ```ts\n * import { ApiError, requestContextOf } from \"@bedrock-rbx/ocale\";\n *\n * const original = new ApiError(\"HTTP 404\", {\n * elapsedMs: 512,\n * method: \"GET\",\n * statusCode: 404,\n * url: \"https://apis.roblox.com/cloud/v2/universes/1\",\n * });\n *\n * const rewrapped = new ApiError(\"Universe 1 was not found; adoption failed\", {\n * ...requestContextOf(original),\n * statusCode: 404,\n * });\n *\n * expect(rewrapped.method).toBe(\"GET\");\n * expect(rewrapped.url).toBe(\"https://apis.roblox.com/cloud/v2/universes/1\");\n * expect(rewrapped.elapsedMs).toBe(512);\n * ```\n */\nexport function requestContextOf(err: ApiError): ApiRequestContext {\n\treturn {\n\t\telapsedMs: err.elapsedMs,\n\t\tgatewaySummary: err.gatewaySummary,\n\t\tmethod: err.method,\n\t\tresponseHeaders: err.responseHeaders,\n\t\tunparsedBodyLength: err.unparsedBodyLength,\n\t\turl: err.url,\n\t};\n}\n","import { OpenCloudError, type OpenCloudErrorOptions } from \"./base.ts\";\n\n/**\n * Which layer refused a 429, as best the SDK can tell from one response.\n * It names the refusing layer only, not the cause of the refusal.\n *\n * - `\"edge\"`: the gateway refused before the request reached the service.\n * - `\"service\"`: the service behind the gateway refused (the response names it\n * in `x-roblox-system-reason`).\n * - `\"unknown\"`: the response has no positive evidence for either layer.\n *\n * @since 0.4.0\n */\nexport type RateLimitSource = \"edge\" | \"service\" | \"unknown\";\n\n/**\n * Options for constructing a {@link RateLimitError}.\n *\n * @since 0.1.0\n */\nexport interface RateLimitErrorOptions extends OpenCloudErrorOptions {\n\t/**\n\t * Parsed 429 response body, when present. Holds the server's 429\n\t * explanation (JSON when the body parses, otherwise the truncated raw\n\t * text) so a rate limit stays diagnosable from the error alone. A literal\n\t * JSON `null` remains `null`; an absent body is `undefined`.\n\t */\n\tdetails?: JSONValue | undefined;\n\t/**\n\t * Requests left in the reported rate-limit window. Read from\n\t * `x-ratelimit-remaining` using the smallest valid token.\n\t *\n\t * `undefined` when the header has no valid non-negative integer token.\n\t *\n\t * Parsed separately from `x-ratelimit-reset`; a valid value survives an\n\t * invalid reset.\n\t *\n\t * This is one budget reading, not a classifier for the cause of the 429.\n\t */\n\tremaining?: number | undefined;\n\t/**\n\t * Allowlisted response headers useful for diagnosing the 429. Values are\n\t * preserved exactly as the Fetch API presents them, including comma-joined\n\t * multi-window values. The full header set is never retained.\n\t */\n\tresponseHeaders?: Readonly<Record<string, string>> | undefined;\n\t/** Seconds to wait before retrying the request. */\n\tretryAfterSeconds: number;\n\t/**\n\t * Which layer refused the request. Defaults to `\"unknown\"`.\n\t *\n\t * @since 0.4.0\n\t */\n\tsource?: RateLimitSource | undefined;\n\t/**\n\t * HTTP status code that produced the error. Always `429` when minted by the\n\t * SDK transport; `undefined` when constructed without one.\n\t */\n\tstatusCode?: number | undefined;\n}\n\n/**\n * Thrown when the Roblox Open Cloud API returns a 429 Too Many Requests\n * response. Contains the server-suggested retry delay and safe,\n * machine-readable response evidence. The body code, remaining budget, and\n * headers do not identify the upstream cause (for example quota vs place\n * capacity). `source` names only the layer that refused the request;\n * `\"unknown\"` means the response carried no positive evidence for either\n * layer.\n *\n * @since 0.1.0\n *\n * @example\n *\n * ```ts\n * import { RateLimitError } from \"@bedrock-rbx/ocale\";\n *\n * const error = new RateLimitError(\"Too many requests\", {\n * code: \"RESOURCE_EXHAUSTED\",\n * remaining: 3,\n * responseHeaders: {\n * \"retry-after\": \"1856\",\n * \"x-ratelimit-limit\": \"5, 5;w=60, 5;w=60\",\n * },\n * retryAfterSeconds: 1856,\n * source: \"service\",\n * });\n *\n * // `source` is a classification; the raw evidence stays available.\n * const evidence = {\n * code: error.code,\n * limit: error.responseHeaders?.[\"x-ratelimit-limit\"],\n * retryAfter: error.responseHeaders?.[\"retry-after\"],\n * source: error.source,\n * };\n *\n * expect(evidence).toEqual({\n * code: \"RESOURCE_EXHAUSTED\",\n * limit: \"5, 5;w=60, 5;w=60\",\n * retryAfter: \"1856\",\n * source: \"service\",\n * });\n * ```\n */\nexport class RateLimitError extends OpenCloudError {\n\t/**\n\t * Parsed 429 response body. A literal JSON `null` remains `null`; an absent\n\t * body is `undefined`.\n\t */\n\tpublic readonly details: JSONValue | undefined;\n\tpublic override readonly name = \"RateLimitError\";\n\t/**\n\t * Requests left in the reported window, or `undefined` if not reported.\n\t */\n\tpublic readonly remaining: number | undefined;\n\t/** Allowlisted raw response headers, or `undefined` if not set. */\n\tpublic readonly responseHeaders: Readonly<Record<string, string>> | undefined;\n\tpublic readonly retryAfterSeconds: number;\n\t/**\n\t * Which layer refused the request, or `\"unknown\"` without evidence.\n\t *\n\t * @since 0.4.0\n\t */\n\tpublic readonly source: RateLimitSource;\n\t/** HTTP status code that produced the error, or `undefined` if not set. */\n\tpublic readonly statusCode: number | undefined;\n\n\t/**\n\t * Creates a new RateLimitError.\n\t *\n\t * @param message - Human-readable error description.\n\t * @param options - Error options including the retry delay.\n\t */\n\tconstructor(message: string, options: RateLimitErrorOptions) {\n\t\tsuper(message, options);\n\t\tthis.retryAfterSeconds = options.retryAfterSeconds;\n\t\tthis.remaining = options.remaining;\n\t\tthis.responseHeaders = options.responseHeaders;\n\t\tthis.details = options.details;\n\t\tthis.statusCode = options.statusCode;\n\t\tthis.source = options.source ?? \"unknown\";\n\t}\n}\n\nconst GUIDED_ERRORS = new WeakSet<RateLimitError>();\n\n/**\n * Marks a transport-minted error whose zero-second delay is explicit guidance.\n *\n * @param error - The classified rate-limit failure.\n * @returns The same error, marked for retry orchestration.\n */\nexport function markServerRetryGuidance(error: RateLimitError): RateLimitError {\n\tGUIDED_ERRORS.add(error);\n\treturn error;\n}\n\n/**\n * Checks whether an error carries applicable server retry guidance.\n *\n * @param error - The rate-limit failure to inspect.\n * @returns Whether its delay should override caller backoff.\n */\nexport function hasServerRetryGuidance(error: RateLimitError): boolean {\n\treturn error.retryAfterSeconds > 0 || GUIDED_ERRORS.has(error);\n}\n","import { OpenCloudError } from \"./base.ts\";\n\n/**\n * Options for constructing a {@link NetworkError}.\n *\n * @since 0.1.0\n */\nexport interface NetworkErrorOptions extends ErrorOptions {\n\t/** HTTP method of the request that failed. */\n\tmethod?: string | undefined;\n\t/** Fully-qualified URL of the request that failed. */\n\turl?: string | undefined;\n}\n\n/**\n * Thrown when a network-level failure prevents the request from reaching\n * the Roblox Open Cloud API (e.g., DNS resolution failure, connection reset).\n * The `method` and `url` name the failing call so a transport failure that\n * survives every retry can be diagnosed; the underlying transport error is\n * carried on `cause`.\n *\n * @since 0.1.0\n */\nexport class NetworkError extends OpenCloudError {\n\tpublic readonly method: string | undefined;\n\tpublic override readonly name: string = \"NetworkError\";\n\tpublic readonly url: string | undefined;\n\n\t/**\n\t * Creates a new NetworkError.\n\t *\n\t * @param message - Human-readable error description.\n\t * @param options - Error options including the optional `cause` and the\n\t * `method` / `url` of the request that failed.\n\t */\n\tconstructor(message: string, options?: NetworkErrorOptions) {\n\t\tsuper(message, options);\n\t\tthis.method = options?.method;\n\t\tthis.url = options?.url;\n\t}\n}\n"],"mappings":";AAeA,MAAM,uBAAsD,OAAO,OAAO,CAAC,CAAC;AAE5E,MAAM,oCAAoB,IAAI,QAAuD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8BrF,IAAa,iBAAb,cAAoC,MAAM;;CAEzC;CACA,OAAwC;;;;;;;;CASxC,YAAY,SAAkB,SAAiC;EAC9D,MAAM,SAAS,OAAO;EACtB,KAAK,OAAO,SAAS;CACtB;;;;;;;;;CAUA,IAAW,mBAAkD;EAC5D,OAAO,kBAAkB,IAAI,IAAI,KAAK;CACvC;AACD;;;;;;;;;;AAWA,SAAgB,uBACf,OACA,UACiB;CACjB,kBAAkB,IAAI,OAAO,OAAO,OAAO,CAAC,GAAG,QAAQ,CAAC,CAAC;CACzD,OAAO;AACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACJA,IAAa,WAAb,cAA8B,eAAe;CAC5C;CACA;CACA;CACA;CACA,OAAwC;CACxC;CACA;CACA;CACA;;;;;;;;;;CAWA,YAAY,SAAiB,SAA0B;EACtD,MAAM,SAAS,OAAO;EACtB,KAAK,aAAa,QAAQ;EAC1B,KAAK,UAAU,QAAQ;EACvB,KAAK,SAAS,QAAQ;EACtB,KAAK,MAAM,QAAQ;EACnB,KAAK,YAAY,QAAQ;EACzB,KAAK,kBAAkB,QAAQ;EAC/B,KAAK,iBAAiB,QAAQ;EAC9B,KAAK,qBAAqB,QAAQ;CACnC;AACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmCA,SAAgB,iBAAiB,KAAkC;CAClE,OAAO;EACN,WAAW,IAAI;EACf,gBAAgB,IAAI;EACpB,QAAQ,IAAI;EACZ,iBAAiB,IAAI;EACrB,oBAAoB,IAAI;EACxB,KAAK,IAAI;CACV;AACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC3DA,IAAa,iBAAb,cAAoC,eAAe;;;;;CAKlD;CACA,OAAgC;;;;CAIhC;;CAEA;CACA;;;;;;CAMA;;CAEA;;;;;;;CAQA,YAAY,SAAiB,SAAgC;EAC5D,MAAM,SAAS,OAAO;EACtB,KAAK,oBAAoB,QAAQ;EACjC,KAAK,YAAY,QAAQ;EACzB,KAAK,kBAAkB,QAAQ;EAC/B,KAAK,UAAU,QAAQ;EACvB,KAAK,aAAa,QAAQ;EAC1B,KAAK,SAAS,QAAQ,UAAU;CACjC;AACD;AAEA,MAAM,gCAAgB,IAAI,QAAwB;;;;;;;AAQlD,SAAgB,wBAAwB,OAAuC;CAC9E,cAAc,IAAI,KAAK;CACvB,OAAO;AACR;;;;;;;AAQA,SAAgB,uBAAuB,OAAgC;CACtE,OAAO,MAAM,oBAAoB,KAAK,cAAc,IAAI,KAAK;AAC9D;;;;;;;;;;;;AC9IA,IAAa,eAAb,cAAkC,eAAe;CAChD;CACA,OAAwC;CACxC;;;;;;;;CASA,YAAY,SAAiB,SAA+B;EAC3D,MAAM,SAAS,OAAO;EACtB,KAAK,SAAS,SAAS;EACvB,KAAK,MAAM,SAAS;CACrB;AACD"}
|
package/dist/places.d.mts
CHANGED
|
@@ -1,15 +1,25 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a as ListLogsParameters, f as LuauExecutionTask, h as SubmitAtVersionParameters, m as SubmitAtHeadParameters, n as LuauExecutionSubmitOptions, o as LogMessage, p as LuauExecutionTaskRef, r as PollUntilDoneOptions, s as LogPage, t as LuauExecutionRunOptions, u as GetParameters } from "./capacity-admission-
|
|
3
|
-
|
|
1
|
+
import { c as OpenCloudClientOptions, d as RequestOptions, g as OpenCloudError, m as Result } from "./types-CdMr_J1M.mjs";
|
|
2
|
+
import { a as ListLogsParameters, f as LuauExecutionTask, h as SubmitAtVersionParameters, m as SubmitAtHeadParameters, n as LuauExecutionSubmitOptions, o as LogMessage, p as LuauExecutionTaskRef, r as PollUntilDoneOptions, s as LogPage, t as LuauExecutionRunOptions, u as GetParameters } from "./capacity-admission-hycCFkTo.mjs";
|
|
4
3
|
//#region src/domains/cloud-v2/places/types.d.ts
|
|
5
4
|
/**
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
5
|
+
* Identifies a place to read through `PlacesClient.get`.
|
|
6
|
+
*
|
|
7
|
+
* @since 0.4.0
|
|
8
|
+
*/
|
|
9
|
+
interface GetPlaceParameters {
|
|
10
|
+
/** Stringified place ID. */
|
|
11
|
+
readonly placeId: string;
|
|
12
|
+
/** Stringified ID of the universe that owns the place. */
|
|
13
|
+
readonly universeId: string;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Caller-supplied input for the `update` method on `PlacesClient`.
|
|
17
|
+
* Every writable field is optional; presence of a key drives the
|
|
18
|
+
* `updateMask` query string that the server uses as the field-mask
|
|
19
|
+
* for the partial update. Absent keys are left untouched server-side.
|
|
20
|
+
*
|
|
21
|
+
* @since 0.1.0
|
|
22
|
+
*/
|
|
13
23
|
interface UpdatePlaceParameters {
|
|
14
24
|
/** New description for the place. */
|
|
15
25
|
readonly description?: string;
|
|
@@ -23,11 +33,11 @@ interface UpdatePlaceParameters {
|
|
|
23
33
|
readonly universeId: string;
|
|
24
34
|
}
|
|
25
35
|
/**
|
|
26
|
-
* Parsed representation of a Roblox place's configuration, as returned
|
|
27
|
-
* by the Open Cloud `Cloud_GetPlace` and `Cloud_UpdatePlace` endpoints.
|
|
28
|
-
*
|
|
29
|
-
* @since 0.1.0
|
|
30
|
-
*/
|
|
36
|
+
* Parsed representation of a Roblox place's configuration, as returned
|
|
37
|
+
* by the Open Cloud `Cloud_GetPlace` and `Cloud_UpdatePlace` endpoints.
|
|
38
|
+
*
|
|
39
|
+
* @since 0.1.0
|
|
40
|
+
*/
|
|
31
41
|
interface Place {
|
|
32
42
|
/** Stringified place ID, extracted from the wire `path`. */
|
|
33
43
|
readonly id: string;
|
|
@@ -51,22 +61,22 @@ interface Place {
|
|
|
51
61
|
//#endregion
|
|
52
62
|
//#region src/domains/universes/places/types.d.ts
|
|
53
63
|
/**
|
|
54
|
-
* Caller-supplied input for the `publish` and `save` methods on
|
|
55
|
-
* `PlacesClient`. Both methods take the same parameter shape; which
|
|
56
|
-
* version-type query string is used is decided by the method, not the
|
|
57
|
-
* caller.
|
|
58
|
-
*
|
|
59
|
-
* @since 0.1.0
|
|
60
|
-
*/
|
|
64
|
+
* Caller-supplied input for the `publish` and `save` methods on
|
|
65
|
+
* `PlacesClient`. Both methods take the same parameter shape; which
|
|
66
|
+
* version-type query string is used is decided by the method, not the
|
|
67
|
+
* caller.
|
|
68
|
+
*
|
|
69
|
+
* @since 0.1.0
|
|
70
|
+
*/
|
|
61
71
|
interface PublishParameters {
|
|
62
72
|
/** Raw `.rbxl` or `.rbxlx` file bytes. Must be non-empty. */
|
|
63
73
|
readonly body: Uint8Array<ArrayBuffer>;
|
|
64
74
|
/**
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
75
|
+
* Whether `body` is the binary or XML place format. The transport
|
|
76
|
+
* sends `application/octet-stream` for `"rbxl"` and `application/xml`
|
|
77
|
+
* for `"rbxlx"`, and the builder rejects payloads whose magic bytes
|
|
78
|
+
* disagree with the declared format before any HTTP call.
|
|
79
|
+
*/
|
|
70
80
|
readonly format: "rbxl" | "rbxlx";
|
|
71
81
|
/** Stringified ID of the place inside the universe. */
|
|
72
82
|
readonly placeId: string;
|
|
@@ -74,189 +84,203 @@ interface PublishParameters {
|
|
|
74
84
|
readonly universeId: string;
|
|
75
85
|
}
|
|
76
86
|
/**
|
|
77
|
-
* Successful response from publishing or saving a new place version.
|
|
78
|
-
*
|
|
79
|
-
* @since 0.1.0
|
|
80
|
-
*/
|
|
87
|
+
* Successful response from publishing or saving a new place version.
|
|
88
|
+
*
|
|
89
|
+
* @since 0.1.0
|
|
90
|
+
*/
|
|
81
91
|
interface PlaceVersion {
|
|
82
92
|
/**
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
93
|
+
* Auto-incrementing version number assigned by Roblox. Always at least
|
|
94
|
+
* `1` for the first publish; increases by one for every subsequent
|
|
95
|
+
* publish or save against the same place.
|
|
96
|
+
*/
|
|
87
97
|
readonly versionNumber: number;
|
|
88
98
|
}
|
|
89
99
|
//#endregion
|
|
90
100
|
//#region src/resources/places/client.d.ts
|
|
91
101
|
/**
|
|
92
|
-
* Operation Group exposed by {@link PlacesClient} as the
|
|
93
|
-
* `luauExecution` namespace. Provides `submit` to queue a Luau script,
|
|
94
|
-
* `get` to fetch a task's current state, and `listLogs` to retrieve
|
|
95
|
-
* structured log messages. Shares the same dispatch wiring as the
|
|
96
|
-
* top-level `LuauExecutionClient` exposed at
|
|
97
|
-
* `@bedrock-rbx/ocale/luau-execution`.
|
|
98
|
-
*
|
|
99
|
-
* @since 0.1.0
|
|
100
|
-
*/
|
|
102
|
+
* Operation Group exposed by {@link PlacesClient} as the
|
|
103
|
+
* `luauExecution` namespace. Provides `submit` to queue a Luau script,
|
|
104
|
+
* `get` to fetch a task's current state, and `listLogs` to retrieve
|
|
105
|
+
* structured log messages. Shares the same dispatch wiring as the
|
|
106
|
+
* top-level `LuauExecutionClient` exposed at
|
|
107
|
+
* `@bedrock-rbx/ocale/luau-execution`.
|
|
108
|
+
*
|
|
109
|
+
* @since 0.1.0
|
|
110
|
+
*/
|
|
101
111
|
interface LuauExecutionHandle {
|
|
102
112
|
/**
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
113
|
+
* Fetches the current state of a previously-submitted Luau
|
|
114
|
+
* execution task. Uses idempotent retry semantics for both 429 and
|
|
115
|
+
* 5xx.
|
|
116
|
+
*
|
|
117
|
+
* @param parameters - The task ref plus an optional `view` selector.
|
|
118
|
+
* @param options - Optional per-request overrides (e.g. A different
|
|
119
|
+
* {@link OpenCloudClientOptions.credential} for this call only).
|
|
120
|
+
* @returns A {@link Result} wrapping the parsed
|
|
121
|
+
* {@link LuauExecutionTask} or the {@link OpenCloudError} that
|
|
122
|
+
* caused the request to fail.
|
|
123
|
+
*/
|
|
114
124
|
get(parameters: GetParameters, options?: RequestOptions): Promise<Result<LuauExecutionTask, OpenCloudError>>;
|
|
115
125
|
/**
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
126
|
+
* Lists one page of structured log messages produced by a
|
|
127
|
+
* previously-submitted Luau execution task. Messages from multiple
|
|
128
|
+
* server-side chunks are flattened into a single ordered array.
|
|
129
|
+
* Uses idempotent retry semantics for both 429 and 5xx.
|
|
130
|
+
*
|
|
131
|
+
* @param parameters - The task ref and optional pagination controls
|
|
132
|
+
* (`pageSize`, `pageToken`).
|
|
133
|
+
* @param options - Optional per-request overrides (e.g. A different
|
|
134
|
+
* {@link OpenCloudClientOptions.credential} for this call only).
|
|
135
|
+
* @returns A {@link Result} wrapping the parsed {@link LogPage} or
|
|
136
|
+
* the {@link OpenCloudError} that caused the request to fail.
|
|
137
|
+
*/
|
|
128
138
|
listLogs(parameters: ListLogsParameters, options?: RequestOptions): Promise<Result<LogPage, OpenCloudError>>;
|
|
129
139
|
/**
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
+
* Polls `get` with `view=BASIC` on a configurable backoff schedule until
|
|
141
|
+
* the task reaches a terminal state, the wall-clock budget is exhausted,
|
|
142
|
+
* or the supplied `AbortSignal` fires. Returns the terminal task on
|
|
143
|
+
* success. The budget also bounds an in-flight
|
|
144
|
+
* request through its request deadline, so a hanging request ends with
|
|
145
|
+
* `PollTimeoutError` at the budget.
|
|
146
|
+
*
|
|
147
|
+
* @param ref - Reference to the task to poll, typically returned by `submit`.
|
|
148
|
+
* @param options - Polling and per-request overrides.
|
|
149
|
+
* @returns A {@link Result} wrapping the terminal {@link LuauExecutionTask},
|
|
150
|
+
* or an error if aborted, timed out, or the transport fails.
|
|
151
|
+
*/
|
|
140
152
|
pollUntilDone(ref: LuauExecutionTaskRef, options?: PollUntilDoneOptions): Promise<Result<LuauExecutionTask, OpenCloudError>>;
|
|
141
153
|
/**
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
154
|
+
* Submits a Luau script and polls `get` with `view=BASIC` until the
|
|
155
|
+
* task reaches a terminal state, the wall-clock budget is exhausted,
|
|
156
|
+
* or the supplied `AbortSignal` fires. Combines `submit` and
|
|
157
|
+
* `pollUntilDone` in one call. The budget opens before the submit
|
|
158
|
+
* and covers it, and bounds each in-flight request through its request
|
|
159
|
+
* deadline.
|
|
160
|
+
*
|
|
161
|
+
* @param parameters - The same input accepted by `submit`.
|
|
162
|
+
* @param options - Polling and per-request overrides.
|
|
163
|
+
* @returns A {@link Result} wrapping the terminal
|
|
164
|
+
* {@link LuauExecutionTask}, or an error if submit fails, the task
|
|
165
|
+
* is aborted, timed out, or the transport fails.
|
|
166
|
+
*/
|
|
153
167
|
runUntilDone(parameters: SubmitAtHeadParameters | SubmitAtVersionParameters, options?: LuauExecutionRunOptions): Promise<Result<LuauExecutionTask, OpenCloudError>>;
|
|
154
168
|
/**
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
+
* Submits a Luau script for execution against a place. Dispatches
|
|
170
|
+
* to the head-version URL when `versionId` is omitted, or to the
|
|
171
|
+
* specific-version URL when one is supplied. Both URL shapes share
|
|
172
|
+
* one rate-limit queue and one required-scope set.
|
|
173
|
+
*
|
|
174
|
+
* @param parameters - The universe and place identifiers, the
|
|
175
|
+
* script to run, an optional `versionId`, and any other writable
|
|
176
|
+
* submit fields.
|
|
177
|
+
* @param options - Optional per-request overrides (e.g. A different
|
|
178
|
+
* {@link OpenCloudClientOptions.credential} for this call only).
|
|
179
|
+
* @returns A {@link Result} wrapping the parsed
|
|
180
|
+
* {@link LuauExecutionTask} or the {@link OpenCloudError} that
|
|
181
|
+
* caused the request to fail.
|
|
182
|
+
*/
|
|
169
183
|
submit(parameters: SubmitAtHeadParameters | SubmitAtVersionParameters, options?: LuauExecutionSubmitOptions): Promise<Result<LuauExecutionTask, OpenCloudError>>;
|
|
170
184
|
}
|
|
171
185
|
/**
|
|
172
|
-
* Public client for the Roblox Open Cloud `Place` resource. Covers
|
|
173
|
-
* place-version publishing (`publish`, `save`), place-configuration
|
|
174
|
-
* updates (`update`), and the Luau execution Operation Group
|
|
175
|
-
* (`luauExecution.submit`, `luauExecution.get`). Every method returns
|
|
176
|
-
* a {@link Result} so callers handle failure explicitly; no thrown
|
|
177
|
-
* {@link OpenCloudError} ever escapes the client.
|
|
178
|
-
*
|
|
179
|
-
* Publishing or saving a 5xx-failed place version is not retried
|
|
180
|
-
* automatically: Roblox does not support idempotency keys, so a retry
|
|
181
|
-
* could publish a duplicate version unnoticed. Callers that *can* detect
|
|
182
|
-
* duplicates externally may opt back into 5xx retry per-call by passing
|
|
183
|
-
* `retryableStatuses` on the second argument. The `update` method, by
|
|
184
|
-
* contrast, is idempotent and retries both 429 and 5xx automatically.
|
|
185
|
-
*
|
|
186
|
-
* Failures that never reached Open Cloud *are* retried: transient transport
|
|
187
|
-
* errors, and responses served by an edge gateway rather than the API. Neither
|
|
188
|
-
* can have created a version, so neither risks the duplicate a 5xx does.
|
|
189
|
-
*
|
|
190
|
-
* @since 0.1.0
|
|
191
|
-
*
|
|
192
|
-
* @example
|
|
193
|
-
*
|
|
194
|
-
* ```ts
|
|
195
|
-
* import { PlacesClient } from "@bedrock-rbx/ocale/places";
|
|
196
|
-
*
|
|
197
|
-
* const client = new PlacesClient({ apiKey: "your-key" });
|
|
198
|
-
* expect(client).toBeInstanceOf(PlacesClient);
|
|
199
|
-
* ```
|
|
200
|
-
*/
|
|
201
|
-
declare class PlacesClient {
|
|
186
|
+
* Public client for the Roblox Open Cloud `Place` resource. Covers
|
|
187
|
+
* place-version publishing (`publish`, `save`), place-configuration
|
|
188
|
+
* updates (`update`), and the Luau execution Operation Group
|
|
189
|
+
* (`luauExecution.submit`, `luauExecution.get`). Every method returns
|
|
190
|
+
* a {@link Result} so callers handle failure explicitly; no thrown
|
|
191
|
+
* {@link OpenCloudError} ever escapes the client.
|
|
192
|
+
*
|
|
193
|
+
* Publishing or saving a 5xx-failed place version is not retried
|
|
194
|
+
* automatically: Roblox does not support idempotency keys, so a retry
|
|
195
|
+
* could publish a duplicate version unnoticed. Callers that *can* detect
|
|
196
|
+
* duplicates externally may opt back into 5xx retry per-call by passing
|
|
197
|
+
* `retryableStatuses` on the second argument. The `update` method, by
|
|
198
|
+
* contrast, is idempotent and retries both 429 and 5xx automatically.
|
|
199
|
+
*
|
|
200
|
+
* Failures that never reached Open Cloud *are* retried: transient transport
|
|
201
|
+
* errors, and responses served by an edge gateway rather than the API. Neither
|
|
202
|
+
* can have created a version, so neither risks the duplicate a 5xx does.
|
|
203
|
+
*
|
|
204
|
+
* @since 0.1.0
|
|
205
|
+
*
|
|
206
|
+
* @example
|
|
207
|
+
*
|
|
208
|
+
* ```ts
|
|
209
|
+
* import { PlacesClient } from "@bedrock-rbx/ocale/places";
|
|
210
|
+
*
|
|
211
|
+
* const client = new PlacesClient({ credential: { apiKey: "your-key", kind: "apiKey" } });
|
|
212
|
+
* expect(client).toBeInstanceOf(PlacesClient);
|
|
213
|
+
* ```
|
|
214
|
+
*/
|
|
215
|
+
export declare class PlacesClient {
|
|
202
216
|
#private;
|
|
203
217
|
readonly luauExecution: LuauExecutionHandle;
|
|
204
218
|
/**
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
219
|
+
* Creates a new {@link PlacesClient}. Configuration is frozen on
|
|
220
|
+
* construction; per-request overrides are accepted on each method.
|
|
221
|
+
*
|
|
222
|
+
* @param options - Client-level configuration including the API key.
|
|
223
|
+
*/
|
|
210
224
|
constructor(options: OpenCloudClientOptions);
|
|
211
225
|
/**
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
226
|
+
* Reads a place's configuration, including whether it is the universe's
|
|
227
|
+
* root.
|
|
228
|
+
*
|
|
229
|
+
* @since 0.4.0
|
|
230
|
+
* @param parameters - Owning universe and place identifiers.
|
|
231
|
+
* @param options - Per-request overrides.
|
|
232
|
+
* @returns The parsed place or the Open Cloud failure.
|
|
233
|
+
*/
|
|
234
|
+
get(parameters: GetPlaceParameters, options?: RequestOptions): Promise<Result<Place, OpenCloudError>>;
|
|
235
|
+
/**
|
|
236
|
+
* Publishes a new live version of a place.
|
|
237
|
+
*
|
|
238
|
+
* No default request timeout applies to this upload; pass `options.timeout`
|
|
239
|
+
* to set a per-call deadline.
|
|
240
|
+
*
|
|
241
|
+
* @param parameters - Universe and place identifiers, the place file
|
|
242
|
+
* bytes, and their declared `format`.
|
|
243
|
+
* @param options - Optional per-request overrides (e.g. A different
|
|
244
|
+
* {@link OpenCloudClientOptions.credential} for this call only).
|
|
245
|
+
* @returns A {@link Result} wrapping the parsed {@link PlaceVersion}
|
|
246
|
+
* or the {@link OpenCloudError} that caused the request to fail.
|
|
247
|
+
*/
|
|
224
248
|
publish(parameters: PublishParameters, options?: RequestOptions): Promise<Result<PlaceVersion, OpenCloudError>>;
|
|
225
249
|
/**
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
250
|
+
* Saves a new draft version of a place. Identical to {@link publish}
|
|
251
|
+
* except the resulting version is not made live; consumers can list or
|
|
252
|
+
* promote it later. Shares a single per-API-key rate-limit queue with
|
|
253
|
+
* `publish` because Roblox attributes both calls to the same per-minute
|
|
254
|
+
* quota.
|
|
255
|
+
*
|
|
256
|
+
* No default request timeout applies to this upload; pass `options.timeout`
|
|
257
|
+
* to set a per-call deadline.
|
|
258
|
+
*
|
|
259
|
+
* @param parameters - Universe and place identifiers, the place file
|
|
260
|
+
* bytes, and their declared `format`.
|
|
261
|
+
* @param options - Optional per-request overrides (e.g. A different
|
|
262
|
+
* {@link OpenCloudClientOptions.credential} for this call only).
|
|
263
|
+
* @returns A {@link Result} wrapping the parsed {@link PlaceVersion}
|
|
264
|
+
* or the {@link OpenCloudError} that caused the request to fail.
|
|
265
|
+
*/
|
|
242
266
|
save(parameters: PublishParameters, options?: RequestOptions): Promise<Result<PlaceVersion, OpenCloudError>>;
|
|
243
267
|
/**
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
268
|
+
* Partially updates a place's configuration. The fields supplied on
|
|
269
|
+
* `parameters` (excluding the identifiers) are forwarded to the
|
|
270
|
+
* server via a Google-style `updateMask`; unmentioned fields are
|
|
271
|
+
* left untouched. The universe's root place is the canonical place
|
|
272
|
+
* to update when changing a universe's description or display name:
|
|
273
|
+
* both are derived server-side from the root place.
|
|
274
|
+
*
|
|
275
|
+
* @param parameters - The universe and place identifiers and the
|
|
276
|
+
* fields to update. At least one writable field must be supplied.
|
|
277
|
+
* @param options - Optional per-request overrides (e.g. A different
|
|
278
|
+
* {@link OpenCloudClientOptions.credential} for this call only).
|
|
279
|
+
* @returns A {@link Result} wrapping the parsed {@link Place} or
|
|
280
|
+
* the {@link OpenCloudError} that caused the request to fail.
|
|
281
|
+
*/
|
|
258
282
|
update(parameters: UpdatePlaceParameters, options?: RequestOptions): Promise<Result<Place, OpenCloudError>>;
|
|
259
283
|
}
|
|
260
284
|
//#endregion
|
|
261
|
-
export {
|
|
285
|
+
export type { GetPlaceParameters, ListLogsParameters, LogMessage, LogPage, LuauExecutionHandle, Place, PlaceVersion, PublishParameters, UpdatePlaceParameters };
|
|
262
286
|
//# sourceMappingURL=places.d.mts.map
|
package/dist/places.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"places.d.mts","names":[],"sources":["../src/domains/cloud-v2/places/types.ts","../src/domains/universes/places/types.ts","../src/resources/places/client.ts"],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"file":"places.d.mts","names":[],"sources":["../src/domains/cloud-v2/places/types.ts","../src/domains/universes/places/types.ts","../src/resources/places/client.ts"],"mappings":";;;;;;;;UAKiB;;WAEP;;WAEA;;;;;;;;;;UAWO;;WAEP;;WAEA;;WAEA;;WAEA;;WAEA;;;;;;;;UASO;;WAEP;;WAEA,WAAW;;WAEX;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA,WAAW;;;;;;;;;;;;UCjDJ;;WAEP,MAAM,WAAW;;;;;;;WAOjB;;WAEA;;WAEA;;;;;;;UAQO;;;;;;WAMP;;;;;;;;;;;;;;UCwBO;;;;;;;;;;;;;EAahB,IACC,YAAY,eACZ,UAAU,iBACR,QAAQ,OAAO,mBAAmB;;;;;;;;;;;;;;EAcrC,SACC,YAAY,oBACZ,UAAU,iBACR,QAAQ,OAAO,SAAS;;;;;;;;;;;;;;EAc3B,cACC,KAAK,sBACL,UAAU,uBACR,QAAQ,OAAO,mBAAmB;;;;;;;;;;;;;;;EAerC,aACC,YAAY,yBAAyB,2BACrC,UAAU,0BACR,QAAQ,OAAO,mBAAmB;;;;;;;;;;;;;;;;EAgBrC,OACC,YAAY,yBAAyB,2BACrC,UAAU,6BACR,QAAQ,OAAO,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBAqEzB;;WAGI,eAAe;;;;;;;EAQ/B,YAAY,SAAS;;;;;;;;;;EAcrB,IACC,YAAY,oBACZ,UAAU,iBACR,QAAQ,OAAO,OAAO;;;;;;;;;;;;;;EAiBzB,QACC,YAAY,mBACZ,UAAU,iBACR,QAAQ,OAAO,cAAc;;;;;;;;;;;;;;;;;;EAqBhC,KACC,YAAY,mBACZ,UAAU,iBACR,QAAQ,OAAO,cAAc;;;;;;;;;;;;;;;;EAmBhC,OACC,YAAY,uBACZ,UAAU,iBACR,QAAQ,OAAO,OAAO"}
|