Skip to content

[INTER-708] Response transparency and webhook validation#104

Merged
TheUnderScorer merged 45 commits intotestfrom
feature/INTER-708-response-transparency
Jun 13, 2024
Merged

[INTER-708] Response transparency and webhook validation#104
TheUnderScorer merged 45 commits intotestfrom
feature/INTER-708-response-transparency

Conversation

@TheUnderScorer
Copy link
Copy Markdown
Contributor

@TheUnderScorer TheUnderScorer commented May 29, 2024

  • Expose raw response in case of errors (in case of success it doesn't make sense, because customer can access all response data anyway since we don't transform the data in any way)
  • Sync with OpenAPI schema
  • Add utility function for validating webhook signature
  • Use inline snapshots (better compatibility with our actions with pull_request_target trigger)

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented May 29, 2024

Coverage report

St.
Category Percentage Covered / Total
🟢 Statements
97.06% (-0.08% 🔻)
165/170
🟢 Branches
88.14% (-1.64% 🔻)
104/118
🟢 Functions 100% 39/39
🟢 Lines
97.04% (-0.08% 🔻)
164/169
Show new covered files 🐣
St.
File Statements Branches Functions Lines
🟢 webhook.ts 100% 100% 100% 100%
Show files with reduced coverage 🔻
St.
File Statements Branches Functions Lines
🟢 types.ts 100%
90.48% (-2.55% 🔻)
100% 100%
🟢 urlUtils.ts
97.14% (-2.86% 🔻)
85.71% (-14.29% 🔻)
100%
97.14% (-2.86% 🔻)

Test suite run success

81 tests passing in 10 suites.

Report generated by 🧪jest coverage report action from 76b4e15

Show full coverage report
St File % Stmts % Branch % Funcs % Lines Uncovered Line #s
🟢 All files 97.05 88.13 100 97.04
🟢  src 96.77 88.03 100 96.77
🟢   index.ts 100 100 100 100
🟢   sealedResults.ts 100 100 100 100
🟢   serverApiClient.ts 92.3 80 100 92.3 34,68,127,195
🟢   types.ts 100 90.47 100 100 78-90,117,120
🟢   urlUtils.ts 97.14 85.71 100 97.14 41
🟢   webhook.ts 100 100 100 100
🟢  src/errors 100 100 100 100
🟢   unsealError.ts 100 100 100 100

Orkuncakilkaya
Orkuncakilkaya previously approved these changes May 30, 2024
@JuroUhlar JuroUhlar self-requested a review May 31, 2024 10:17
@TheUnderScorer TheUnderScorer changed the base branch from main to test May 31, 2024 10:22
@TheUnderScorer TheUnderScorer requested a review from JuroUhlar June 12, 2024 08:28
Copy link
Copy Markdown
Contributor

@JuroUhlar JuroUhlar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice job!

@github-actions
Copy link
Copy Markdown
Contributor

This PR will create a minor release 🚀

4.1.0 (2024-06-13)

Features

  • add checkWebhookHeader function for validating webhook signature [INTER-731] (b4d7652)
  • add delete API (9f581ab)
  • add os Mismatch (c3ca8d7)
  • add revision string field to confidence object (a664c2d)
  • expose raw response in errors (79b2fc7)
  • make Options.region optional (673f7ad)
  • provide error as-is without serialization in getEvent method (aee3242)

Documentation

  • README: remove ipLocation field (ef69009)

@TheUnderScorer TheUnderScorer merged commit 1dfe934 into test Jun 13, 2024
@TheUnderScorer TheUnderScorer deleted the feature/INTER-708-response-transparency branch June 13, 2024 11:32
@fingerprint-dx-team
Copy link
Copy Markdown

🎉 This PR is included in version 4.1.0-test.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@fingerprint-dx-team
Copy link
Copy Markdown

🎉 This PR is included in version 4.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants