Cotal TypeScript packages
    Preparing search index...

    Function authorizeRemoteRunAttempt

    • Host-only authorization for RemoteRunAttemptRequest. Every coordinate the returned grant pins is derived from host stores: the admission must exist on this instance and be unrevoked for an attempt or answer. A read-only operator can inspect a revoked run. The attempt must be exactly the next epoch/fencing token the status and journal imply (1/1 for a first attempt with no record, as stock start launches), and an answer pins the pause the named run's journal records at the named step, which must be waiting. Refuses before the host signs anything.

      Parameters

      • args: {
            accountPublicKey: string;
            checkpointSettled: (token: string) => Promise<boolean>;
            checkpointWaiting: (token: string) => Promise<boolean>;
            endpoint: string;
            isLiveManagedActor?: (
                owner: string,
                actor: string,
                lifecycleUid: string,
            ) => boolean;
            issued?: IssuedStore;
            observeManagerGate: ObserveManagerGate;
            owner: string;
            proofSecret: string | Uint8Array<ArrayBufferLike>;
            readAdmission: (runId: string) => Promise<RunAdmissionView>;
            readJournal: (runId: string) => Promise<RunJournalReplay>;
            readRunStatus: (runId: string) => Promise<RunStatusValue | undefined>;
            registeredCommand?: RegisteredRunCommand;
            request: unknown;
            sourceIsLive?: (source: IssuedSourceRef) => Promise<boolean>;
            space: string;
            takeObserved?: (subject: string) => Promise<ObservedRunRequest | undefined>;
        }
        • accountPublicKey: string
        • checkpointSettled: (token: string) => Promise<boolean>

          Whether the pause settled resumed naming an accepted answer: what an amendment amends.

        • checkpointWaiting: (token: string) => Promise<boolean>
        • endpoint: string
        • OptionalisLiveManagedActor?: (owner: string, actor: string, lifecycleUid: string) => boolean
        • Optionalissued?: IssuedStore

          The issued store, the source and ledger checks, the observed requests and the registered declarations a request carrying served is checked with. takeObserved consumes the one observation of a subject and returns what its request asked for.

        • observeManagerGate: ObserveManagerGate
        • owner: string
        • proofSecret: string | Uint8Array<ArrayBufferLike>
        • readAdmission: (runId: string) => Promise<RunAdmissionView>
        • readJournal: (runId: string) => Promise<RunJournalReplay>

          The named run's journal, including activations that have not noted their status yet.

        • readRunStatus: (runId: string) => Promise<RunStatusValue | undefined>
        • OptionalregisteredCommand?: RegisteredRunCommand
        • request: unknown
        • OptionalsourceIsLive?: (source: IssuedSourceRef) => Promise<boolean>
        • space: string
        • OptionaltakeObserved?: (subject: string) => Promise<ObservedRunRequest | undefined>

      Returns Promise<RemoteRunAttemptGrant>