From 1655becf393e363c9cb8f9b7a51c1277248d50cc Mon Sep 17 00:00:00 2001 From: Rogier Reerink Date: Fri, 9 Oct 2026 20:37:36 +0200 Subject: [PATCH] Use Postman built-in auth flow. --- .../.resources/definition.yaml | 39 +++++++++++++++++-- .../API/Accounts/Delete account.request.yaml | 2 +- .../API/Accounts/Get account.request.yaml | 2 +- .../API/Accounts/List accounts.request.yaml | 2 +- .../API/Accounts/Upsert account.request.yaml | 2 +- .../Get challenge options.request.yaml | 2 +- .../Verify challenge response.request.yaml | 2 +- .../API/Auth/Token/Refresh token.request.yaml | 2 +- ...oken using client credentials.request.yaml | 2 +- .../API/Auth/Token/Revoke token.request.yaml | 2 +- .../Delete scheduled transaction.request.yaml | 2 +- .../Get scheduled transaction.request.yaml | 2 +- .../List scheduled transactions.request.yaml | 2 +- .../Upsert scheduled transaction.request.yaml | 2 +- .../Delete transaction.request.yaml | 2 +- .../Transactions/Get transaction.request.yaml | 2 +- .../List transactions.request.yaml | 2 +- .../Upsert transaction.request.yaml | 2 +- .../API/Users/Apps/Delete app.request.yaml | 2 +- .../API/Users/Apps/Get app.request.yaml | 2 +- .../API/Users/Apps/List apps.request.yaml | 2 +- .../Apps/Secrets/Delete secret.request.yaml | 2 +- .../Apps/Secrets/Get secret.request.yaml | 2 +- .../Apps/Secrets/List secrets.request.yaml | 2 +- .../Apps/Secrets/Upsert secret.request.yaml | 2 +- .../API/Users/Apps/Upsert app.request.yaml | 2 +- .../API/Users/Delete user.request.yaml | 2 +- .../API/Users/Get user.request.yaml | 2 +- .../API/Users/List users.request.yaml | 2 +- .../API/Users/Upsert user.request.yaml | 2 +- .../Expenses Server/Health.request.yaml | 2 +- 31 files changed, 66 insertions(+), 33 deletions(-) diff --git a/postman/collections/Expenses Server/.resources/definition.yaml b/postman/collections/Expenses Server/.resources/definition.yaml index 102a94e..059330b 100644 --- a/postman/collections/Expenses Server/.resources/definition.yaml +++ b/postman/collections/Expenses Server/.resources/definition.yaml @@ -1,7 +1,13 @@ $kind: collection variables: + - key: base_url + value: http://localhost:3000 + disabled: false + - key: token_url + value: "{{base_url}}/api/auth/token" + disabled: false - key: user_app_id - value: "" + value: 00000000-0000-0000-0001-000000000001 disabled: false - key: user_app_secret secret: true @@ -13,6 +19,33 @@ variables: secret: true disabled: false auth: - type: bearer + type: oauth2 credentials: - token: "{{access_token}}" + - key: tokenType + value: bearer + - key: token_id + value: "" + - key: accessToken + value: "" + - key: expires_in + value: 0 + - key: timestamp + value: 0 + - key: id + value: "" + - key: tokenName + value: expenses + - key: addTokenTo + value: header + - key: grant_type + value: client_credentials + - key: accessTokenUrl + value: "{{token_url}}" + - key: clientId + value: "{{user_app_id}}" + - key: clientSecret + value: "{{user_app_secret}}" + - key: client_authentication + value: body + - key: id + value: "" diff --git a/postman/collections/Expenses Server/API/Accounts/Delete account.request.yaml b/postman/collections/Expenses Server/API/Accounts/Delete account.request.yaml index 92c1f37..ec5541e 100644 --- a/postman/collections/Expenses Server/API/Accounts/Delete account.request.yaml +++ b/postman/collections/Expenses Server/API/Accounts/Delete account.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/accounts/00000000-0000-0000-0003-000000000001 +url: "{{base_url}}/api/accounts/00000000-0000-0000-0003-000000000001" method: DELETE settings: {} order: 4000 diff --git a/postman/collections/Expenses Server/API/Accounts/Get account.request.yaml b/postman/collections/Expenses Server/API/Accounts/Get account.request.yaml index b535034..4455e90 100644 --- a/postman/collections/Expenses Server/API/Accounts/Get account.request.yaml +++ b/postman/collections/Expenses Server/API/Accounts/Get account.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/accounts/00000000-0000-0000-0003-000000000001 +url: "{{base_url}}/api/accounts/00000000-0000-0000-0003-000000000001" method: GET body: type: text diff --git a/postman/collections/Expenses Server/API/Accounts/List accounts.request.yaml b/postman/collections/Expenses Server/API/Accounts/List accounts.request.yaml index e16888b..7077f73 100644 --- a/postman/collections/Expenses Server/API/Accounts/List accounts.request.yaml +++ b/postman/collections/Expenses Server/API/Accounts/List accounts.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/accounts?name=&limit=20&offset=0 +url: "{{base_url}}/api/accounts?name=&limit=20&offset=0" method: GET queryParams: name: "" diff --git a/postman/collections/Expenses Server/API/Accounts/Upsert account.request.yaml b/postman/collections/Expenses Server/API/Accounts/Upsert account.request.yaml index 4df497a..a89258a 100644 --- a/postman/collections/Expenses Server/API/Accounts/Upsert account.request.yaml +++ b/postman/collections/Expenses Server/API/Accounts/Upsert account.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/accounts/00000000-0000-0000-0003-000000000001 +url: "{{base_url}}/api/accounts/00000000-0000-0000-0003-000000000001" method: PUT body: type: json diff --git a/postman/collections/Expenses Server/API/Auth/Passkey/Get challenge options.request.yaml b/postman/collections/Expenses Server/API/Auth/Passkey/Get challenge options.request.yaml index 0167d6d..d4661be 100644 --- a/postman/collections/Expenses Server/API/Auth/Passkey/Get challenge options.request.yaml +++ b/postman/collections/Expenses Server/API/Auth/Passkey/Get challenge options.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/auth/passkey/options +url: "{{base_url}}/api/auth/passkey/options" method: POST order: 1000 diff --git a/postman/collections/Expenses Server/API/Auth/Passkey/Verify challenge response.request.yaml b/postman/collections/Expenses Server/API/Auth/Passkey/Verify challenge response.request.yaml index 12b361f..e072678 100644 --- a/postman/collections/Expenses Server/API/Auth/Passkey/Verify challenge response.request.yaml +++ b/postman/collections/Expenses Server/API/Auth/Passkey/Verify challenge response.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/auth/passkey/verify +url: "{{base_url}}/api/auth/passkey/verify" method: POST order: 2000 diff --git a/postman/collections/Expenses Server/API/Auth/Token/Refresh token.request.yaml b/postman/collections/Expenses Server/API/Auth/Token/Refresh token.request.yaml index eade643..4885252 100644 --- a/postman/collections/Expenses Server/API/Auth/Token/Refresh token.request.yaml +++ b/postman/collections/Expenses Server/API/Auth/Token/Refresh token.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/auth/token +url: "{{token_url}}" method: POST body: type: urlencoded diff --git a/postman/collections/Expenses Server/API/Auth/Token/Request token using client credentials.request.yaml b/postman/collections/Expenses Server/API/Auth/Token/Request token using client credentials.request.yaml index 972726a..dbe0cbf 100644 --- a/postman/collections/Expenses Server/API/Auth/Token/Request token using client credentials.request.yaml +++ b/postman/collections/Expenses Server/API/Auth/Token/Request token using client credentials.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/auth/token +url: "{{token_url}}" method: POST body: type: urlencoded diff --git a/postman/collections/Expenses Server/API/Auth/Token/Revoke token.request.yaml b/postman/collections/Expenses Server/API/Auth/Token/Revoke token.request.yaml index 32325fd..29cd6fb 100644 --- a/postman/collections/Expenses Server/API/Auth/Token/Revoke token.request.yaml +++ b/postman/collections/Expenses Server/API/Auth/Token/Revoke token.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/auth/token/revoke +url: "{{token_url}}" method: POST body: type: urlencoded diff --git a/postman/collections/Expenses Server/API/Scheduled transactions/Delete scheduled transaction.request.yaml b/postman/collections/Expenses Server/API/Scheduled transactions/Delete scheduled transaction.request.yaml index dc5f4b0..f9b02c3 100644 --- a/postman/collections/Expenses Server/API/Scheduled transactions/Delete scheduled transaction.request.yaml +++ b/postman/collections/Expenses Server/API/Scheduled transactions/Delete scheduled transaction.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/scheduled-transactions/00000000-0000-0000-0005-000000000001 +url: "{{base_url}}/api/scheduled-transactions/00000000-0000-0000-0005-000000000001" method: DELETE settings: {} order: 4000 diff --git a/postman/collections/Expenses Server/API/Scheduled transactions/Get scheduled transaction.request.yaml b/postman/collections/Expenses Server/API/Scheduled transactions/Get scheduled transaction.request.yaml index 5c4052c..5c08ec4 100644 --- a/postman/collections/Expenses Server/API/Scheduled transactions/Get scheduled transaction.request.yaml +++ b/postman/collections/Expenses Server/API/Scheduled transactions/Get scheduled transaction.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/scheduled-transactions/00000000-0000-0000-0005-000000000001 +url: "{{base_url}}/api/scheduled-transactions/00000000-0000-0000-0005-000000000001" method: GET settings: {} order: 2000 diff --git a/postman/collections/Expenses Server/API/Scheduled transactions/List scheduled transactions.request.yaml b/postman/collections/Expenses Server/API/Scheduled transactions/List scheduled transactions.request.yaml index 2317041..0dae85f 100644 --- a/postman/collections/Expenses Server/API/Scheduled transactions/List scheduled transactions.request.yaml +++ b/postman/collections/Expenses Server/API/Scheduled transactions/List scheduled transactions.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/scheduled-transactions?limit=20&offset=0 +url: "{{base_url}}/api/scheduled-transactions?limit=20&offset=0" method: GET queryParams: limit: "20" diff --git a/postman/collections/Expenses Server/API/Scheduled transactions/Upsert scheduled transaction.request.yaml b/postman/collections/Expenses Server/API/Scheduled transactions/Upsert scheduled transaction.request.yaml index d7b1681..0413674 100644 --- a/postman/collections/Expenses Server/API/Scheduled transactions/Upsert scheduled transaction.request.yaml +++ b/postman/collections/Expenses Server/API/Scheduled transactions/Upsert scheduled transaction.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/scheduled-transactions/00000000-0000-0000-0005-000000000001 +url: "{{base_url}}/api/scheduled-transactions/00000000-0000-0000-0005-000000000001" method: PUT body: type: json diff --git a/postman/collections/Expenses Server/API/Transactions/Delete transaction.request.yaml b/postman/collections/Expenses Server/API/Transactions/Delete transaction.request.yaml index 1490624..e3efb7d 100644 --- a/postman/collections/Expenses Server/API/Transactions/Delete transaction.request.yaml +++ b/postman/collections/Expenses Server/API/Transactions/Delete transaction.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/transactions/00000000-0000-0000-0004-000000000001 +url: "{{base_url}}/api/transactions/00000000-0000-0000-0004-000000000001" method: DELETE settings: {} order: 4000 diff --git a/postman/collections/Expenses Server/API/Transactions/Get transaction.request.yaml b/postman/collections/Expenses Server/API/Transactions/Get transaction.request.yaml index 7fdc5b3..7d633a1 100644 --- a/postman/collections/Expenses Server/API/Transactions/Get transaction.request.yaml +++ b/postman/collections/Expenses Server/API/Transactions/Get transaction.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/transactions/00000000-0000-0000-0004-000000000001 +url: "{{base_url}}/api/transactions/00000000-0000-0000-0004-000000000001" method: GET body: type: text diff --git a/postman/collections/Expenses Server/API/Transactions/List transactions.request.yaml b/postman/collections/Expenses Server/API/Transactions/List transactions.request.yaml index 74de1d7..d5d40dd 100644 --- a/postman/collections/Expenses Server/API/Transactions/List transactions.request.yaml +++ b/postman/collections/Expenses Server/API/Transactions/List transactions.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/transactions?limit=20&offset=0 +url: "{{base_url}}/api/transactions?limit=20&offset=0" method: GET queryParams: limit: "20" diff --git a/postman/collections/Expenses Server/API/Transactions/Upsert transaction.request.yaml b/postman/collections/Expenses Server/API/Transactions/Upsert transaction.request.yaml index 4de7b84..110044e 100644 --- a/postman/collections/Expenses Server/API/Transactions/Upsert transaction.request.yaml +++ b/postman/collections/Expenses Server/API/Transactions/Upsert transaction.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/transactions/00000000-0000-0000-0004-000000000001 +url: "{{base_url}}/api/transactions/00000000-0000-0000-0004-000000000001" method: PUT body: type: json diff --git a/postman/collections/Expenses Server/API/Users/Apps/Delete app.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/Delete app.request.yaml index 7c09c2f..dd7d9ea 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/Delete app.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/Delete app.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000003 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000003" method: DELETE order: 5000 diff --git a/postman/collections/Expenses Server/API/Users/Apps/Get app.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/Get app.request.yaml index 434dcd9..be77d15 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/Get app.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/Get app.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000003 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000003" method: GET order: 3000 diff --git a/postman/collections/Expenses Server/API/Users/Apps/List apps.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/List apps.request.yaml index b4dcda0..25157f9 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/List apps.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/List apps.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps" method: GET order: 2000 diff --git a/postman/collections/Expenses Server/API/Users/Apps/Secrets/Delete secret.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/Secrets/Delete secret.request.yaml index 093b06e..aa62b39 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/Secrets/Delete secret.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/Secrets/Delete secret.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets/00000000-0000-0000-0002-000000000001 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets/00000000-0000-0000-0002-000000000001" method: DELETE order: 4000 diff --git a/postman/collections/Expenses Server/API/Users/Apps/Secrets/Get secret.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/Secrets/Get secret.request.yaml index db43a4b..a2d3d92 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/Secrets/Get secret.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/Secrets/Get secret.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets/00000000-0000-0000-0002-000000000001 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets/00000000-0000-0000-0002-000000000001" method: GET order: 2000 diff --git a/postman/collections/Expenses Server/API/Users/Apps/Secrets/List secrets.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/Secrets/List secrets.request.yaml index 1066005..8f79296 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/Secrets/List secrets.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/Secrets/List secrets.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets" method: GET order: 1000 diff --git a/postman/collections/Expenses Server/API/Users/Apps/Secrets/Upsert secret.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/Secrets/Upsert secret.request.yaml index f1f343d..ea4d2d1 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/Secrets/Upsert secret.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/Secrets/Upsert secret.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets/00000000-0000-0000-0002-000000000001 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000001/secrets/00000000-0000-0000-0002-000000000001" method: PUT body: type: json diff --git a/postman/collections/Expenses Server/API/Users/Apps/Upsert app.request.yaml b/postman/collections/Expenses Server/API/Users/Apps/Upsert app.request.yaml index 5717420..baf5e75 100644 --- a/postman/collections/Expenses Server/API/Users/Apps/Upsert app.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Apps/Upsert app.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000003 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001/apps/00000000-0000-0000-0001-000000000003" method: PUT body: type: json diff --git a/postman/collections/Expenses Server/API/Users/Delete user.request.yaml b/postman/collections/Expenses Server/API/Users/Delete user.request.yaml index 2ed8e20..d92a105 100644 --- a/postman/collections/Expenses Server/API/Users/Delete user.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Delete user.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001" method: DELETE order: 5000 diff --git a/postman/collections/Expenses Server/API/Users/Get user.request.yaml b/postman/collections/Expenses Server/API/Users/Get user.request.yaml index e8df37f..36e269a 100644 --- a/postman/collections/Expenses Server/API/Users/Get user.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Get user.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001" method: GET order: 3000 diff --git a/postman/collections/Expenses Server/API/Users/List users.request.yaml b/postman/collections/Expenses Server/API/Users/List users.request.yaml index 21e169b..3c00a03 100644 --- a/postman/collections/Expenses Server/API/Users/List users.request.yaml +++ b/postman/collections/Expenses Server/API/Users/List users.request.yaml @@ -1,4 +1,4 @@ $kind: http-request -url: http://localhost:3000/api/users +url: "{{base_url}}/api/users" method: GET order: 2000 diff --git a/postman/collections/Expenses Server/API/Users/Upsert user.request.yaml b/postman/collections/Expenses Server/API/Users/Upsert user.request.yaml index 7e8f55b..1335d4e 100644 --- a/postman/collections/Expenses Server/API/Users/Upsert user.request.yaml +++ b/postman/collections/Expenses Server/API/Users/Upsert user.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/api/users/00000000-0000-0000-0000-000000000001 +url: "{{base_url}}/api/users/00000000-0000-0000-0000-000000000001" method: PUT body: type: json diff --git a/postman/collections/Expenses Server/Health.request.yaml b/postman/collections/Expenses Server/Health.request.yaml index b47ef7b..80bbe59 100644 --- a/postman/collections/Expenses Server/Health.request.yaml +++ b/postman/collections/Expenses Server/Health.request.yaml @@ -1,5 +1,5 @@ $kind: http-request -url: http://localhost:3000/health +url: "{{base_url}}/health" method: GET settings: {} order: 4426667294982804