Skip to content

Commit

Permalink
chore: Add generic custom token to follow the definitions regex
Browse files Browse the repository at this point in the history
  • Loading branch information
Hantex9 committed Jun 11, 2024
1 parent a66a326 commit e904764
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/features/payments/routers/platform.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ulid } from "ulid";
import { PAGOPA_PLATFORM_SESSION_TOKEN } from "../utils/platform";
import { addPlatformHandler } from "./router";

// Generates a new pagoPA platform session token
addPlatformHandler("post", "/session", (_, res) =>
res.status(201).json({ token: ulid() })
res.status(201).json({ token: PAGOPA_PLATFORM_SESSION_TOKEN })
);
1 change: 1 addition & 0 deletions src/features/payments/utils/platform.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export const PAGOPA_PLATFORM_SESSION_TOKEN = "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJncm91cCI6ImFuZHJvaWQiLCJhdWQiOiJhbmRyb2lkIiwiaXNzIjoiYXBpLnNvY2lhbGRlYWwubmwiLCJtZW1iZXIiOnsibmFtZSI6ImVyaWsifSwiZXhwIjoxNDUyMDgzMjA3LCJpYXQiOjE0NTE5OTY4MDd9.u7ZBa9RB8U4QL8eBk4hmsjg8oFW19AHuen12c8CvLMj0IQUsNqeC-vwNQvAINpgBM0bzDf5cotyrUzf55eXch6mzfKMa-OJXguO-lARp4fc40HaBWbfnEvGe7yEgSESkt6gJNuprG51A6f4AJyNlXG_3u7O4bAMwiPZJc3AAU84_JXC7Vlq1X3FMaLVGmZdxzA4TvYZEiTt_KHoA49UgzeZtNXo3YiDq-GgL1eV8Li01fwy-M--xzbp4cPcY89jkPyYxUIJEoITOULr3zXQwRfYVe6i0P28oyu5ZzAwYCajBb2T98zN7sFJarNmtcxSKNfhCPnMVn3wrpxx4_Kd2Pw";

0 comments on commit e904764

Please sign in to comment.