(input: {
readonly grant: MigrationGrant;
readonly v1ExpiresAt: number | null;
readonly nowMs: number;
})
| 579 | export const SYNTHETIC_CLIENT_CREDENTIALS_TTL_MS = 60 * 60 * 1000; |
| 580 | |
| 581 | export const migrateExpiresAt = (input: { |
| 582 | readonly grant: MigrationGrant; |
| 583 | readonly v1ExpiresAt: number | null; |
| 584 | readonly nowMs: number; |
| 585 | }): number | null => |
| 586 | input.grant === "client_credentials" && input.v1ExpiresAt == null |
| 587 | ? input.nowMs + SYNTHETIC_CLIENT_CREDENTIALS_TTL_MS |
| 588 | : input.v1ExpiresAt; |
| 589 | |
| 590 | // --------------------------------------------------------------------------- |
| 591 | // Source config → v2 integration config. |
no outgoing calls
no test coverage detected