@sealant/api-contracts-next 0.40.0-next.777 → 0.40.0-next.783

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.
@@ -8,6 +8,7 @@ import { ProfilesGroup } from "./profiles.js";
8
8
  import { RegistriesGroup } from "./registries.js";
9
9
  import { RequestRefusal } from "./request-refusal.js";
10
10
  import { ResourceDomainsGroup } from "./resource-domains.js";
11
+ import { ResourceInstancesGroup } from "./resource-instances.js";
11
12
  import { RunsGroup } from "./runs.js";
12
13
  import { SessionsGroup } from "./sessions.js";
13
14
  import { SshKeysGroup } from "./ssh-keys.js";
@@ -29,6 +30,7 @@ export const ControlPlaneAPI = HttpApi.make("sealantControlPlaneApi")
29
30
  .add(GitHubGroup.prefix("/v1/github"))
30
31
  .add(UsersGroup.prefix("/v1/users"))
31
32
  .add(ResourceDomainsGroup.prefix("/v1/resource-domains"))
33
+ .add(ResourceInstancesGroup.prefix("/v1/resource-domains"))
32
34
  // Last, so it reaches every endpoint above (`HttpApi.middleware` skips endpoints added after it).
33
35
  .middleware(RequestRefusal)
34
36
  .annotate(OpenApi.Title, "Sealant Control Plane API")
@@ -39,6 +39,7 @@
39
39
  */
40
40
  import { Schema } from "effect";
41
41
  import { HttpApiEndpoint, HttpApiGroup } from "effect/http-api";
42
+ export declare const ResourceDomainId: Schema.String;
42
43
  /**
43
44
  * The dimensions a budget caps, defined once: the contract's schemas, the database's budget, the
44
45
  * admission check and the SDK all take theirs from these keys. `freedBy` is what makes room in a
@@ -43,7 +43,7 @@ import * as Rec from "effect/Record";
43
43
  import { PersonId, RESOURCE_DOMAIN_ID_PREFIX } from "./person-id.js";
44
44
  const RESOURCE_DOMAIN_ID_PATTERN = new RegExp(`^${RESOURCE_DOMAIN_ID_PREFIX}[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$`);
45
45
  const RESOURCE_DOMAIN_KEY_PATTERN = /^[a-z][a-z0-9-]{0,31}:[A-Za-z0-9._:/@+=-]{1,223}$/;
46
- const ResourceDomainId = Schema.String.check(Schema.makeFilter((id) => RESOURCE_DOMAIN_ID_PATTERN.test(id) ? undefined : "must be a resource domain id (rdm:<uuid>)"));
46
+ export const ResourceDomainId = Schema.String.check(Schema.makeFilter((id) => RESOURCE_DOMAIN_ID_PATTERN.test(id) ? undefined : "must be a resource domain id (rdm:<uuid>)"));
47
47
  const ResourceDomainKey = Schema.String.check(Schema.makeFilter((key) => RESOURCE_DOMAIN_KEY_PATTERN.test(key)
48
48
  ? undefined
49
49
  : "must be <application>:<name>: a lower-case application name (letters, digits, '-'), a colon, then at most 223 letters, digits, '.', '_', ':', '/', '@', '+', '=' or '-'"));