[codex] Inline contracts request-context service shapes (#3204)

Co-authored-by: codex <[email protected]>
This commit is contained in:
Julius Marmingeandcodex authored and GitHub committed 2026-06-20 02:34:44 +00:00
1 parent 753bc4672d
commit ab0baaa886
1 file changed
+11 -15
+11 -15
View File
@@ -1,5 +1,5 @@
import * as Schema from "effect/Schema";
import * as Context from "effect/Context";
import * as Schema from "effect/Schema";
import * as HttpApi from "effect/unstable/httpapi/HttpApi";
import * as HttpApiEndpoint from "effect/unstable/httpapi/HttpApiEndpoint";
import * as HttpApiGroup from "effect/unstable/httpapi/HttpApiGroup";
@@ -512,26 +512,22 @@ const RelayAgentActivityPublishErrors = [
RelayInternalError,
] as const;
export interface RelayClientPrincipalShape {
readonly userId: string;
readonly token: string;
readonly proofKeyThumbprint?: string;
readonly dpopScopes?: ReadonlyArray<RelayDpopAccessTokenScope>;
}
export class RelayClientPrincipal extends Context.Service<
RelayClientPrincipal,
RelayClientPrincipalShape
{
readonly userId: string;
readonly token: string;
readonly proofKeyThumbprint?: string;
readonly dpopScopes?: ReadonlyArray<RelayDpopAccessTokenScope>;
}
>()("@t3tools/contracts/relay/RelayClientPrincipal") {}
export interface RelayEnvironmentPrincipalShape {
readonly environmentId: string;
readonly environmentPublicKey: string;
}
export class RelayEnvironmentPrincipal extends Context.Service<
RelayEnvironmentPrincipal,
RelayEnvironmentPrincipalShape
{
readonly environmentId: string;
readonly environmentPublicKey: string;
}
>()("@t3tools/contracts/relay/RelayEnvironmentPrincipal") {}
const RelayClientBearerAuthorization = HttpApiSecurity.http({ scheme: "bearer" }).pipe(