mirror of
https://github.com/moltbot/moltbot.git
synced 2026-04-25 23:47:20 +00:00
* feat(push): add ios apns relay gateway * fix(shared): avoid oslog string concatenation # Conflicts: # apps/shared/OpenClawKit/Sources/OpenClawKit/GatewayChannel.swift * fix(push): harden relay validation and invalidation * fix(push): persist app attest state before relay registration * fix(push): harden relay invalidation and url handling * feat(push): use scoped relay send grants * feat(push): configure ios relay through gateway config * feat(push): bind relay registration to gateway identity * fix(push): tighten ios relay trust flow * fix(push): bound APNs registration fields (#43369) (thanks @ngutman)
29 lines
824 B
TypeScript
29 lines
824 B
TypeScript
import { Type } from "@sinclair/typebox";
|
|
import { NonEmptyString } from "./primitives.js";
|
|
|
|
const ApnsEnvironmentSchema = Type.String({ enum: ["sandbox", "production"] });
|
|
|
|
export const PushTestParamsSchema = Type.Object(
|
|
{
|
|
nodeId: NonEmptyString,
|
|
title: Type.Optional(Type.String()),
|
|
body: Type.Optional(Type.String()),
|
|
environment: Type.Optional(ApnsEnvironmentSchema),
|
|
},
|
|
{ additionalProperties: false },
|
|
);
|
|
|
|
export const PushTestResultSchema = Type.Object(
|
|
{
|
|
ok: Type.Boolean(),
|
|
status: Type.Integer(),
|
|
apnsId: Type.Optional(Type.String()),
|
|
reason: Type.Optional(Type.String()),
|
|
tokenSuffix: Type.String(),
|
|
topic: Type.String(),
|
|
environment: ApnsEnvironmentSchema,
|
|
transport: Type.String({ enum: ["direct", "relay"] }),
|
|
},
|
|
{ additionalProperties: false },
|
|
);
|