paubox_rails 0.1.6 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ba84eed39a1ced7a4188e3b4d556e1eb0319af123cc42321bb13d07cadae126a
4
- data.tar.gz: b146f6a504896c8c23a583de9ed7d0130b405aa07a8e6e20841a38aeff313f91
3
+ metadata.gz: efb96c5633f721a96323beab83ed91499817cc05e7e740da733d2ea3db907988
4
+ data.tar.gz: 766ce4809c4a6a74dee3c9614ec50407f8daa04351b00c6b5834126b1a9b7eb3
5
5
  SHA512:
6
- metadata.gz: 13add0018eaa4d54876b6ad7c34f99eb6929e1586a2f9bc0dea605ec8ba965f0b6ab9935b622c5ecbc68f196849dabf14978aeae3bcd9a7d429d7e35ad9354d9
7
- data.tar.gz: d7b3839e27cd935f360dc5d919f68e2e0ea9820db93bceb003f90d1f9ffaca47494a938c3d954ae67e785d553f4e7aba4284f156ac7d630d012fa23bd60478b1
6
+ metadata.gz: bd37d1a222575dafaae87e3afd92fe5dd54874778c1dff2ec2ae00a78ad42278873e509d3ec00eeb5616416434d7a74f6cd25593e1f472dc565bb9d33c805e83
7
+ data.tar.gz: bb9f9c170c09bb5aa043db76acdece25fb1a4bf089f11b2e3ecde245408ea88663718e8e2480b4befd1d7c892a7c9b1507567efda15ead0d6febe5a7d3752a60
@@ -0,0 +1,40 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ # Fail CI when a green rspec exit code does not mean the suite ran.
5
+ #
6
+ # A passing run is not evidence of coverage: an error outside an example, a
7
+ # stray tag filter, or a spec_helper that stops loading files can leave rspec
8
+ # reporting success having executed almost nothing. The failure mode is
9
+ # invisible precisely because the exit code is 0.
10
+
11
+ require 'json'
12
+
13
+ # Floor, not a target. Only trips if coverage regresses; adding specs is free.
14
+ MIN_EXAMPLES = 120
15
+
16
+ summary = JSON.parse(File.read(ARGV.fetch(0))).fetch('summary')
17
+
18
+ total = summary.fetch('example_count')
19
+ pending = summary.fetch('pending_count')
20
+ failures = summary.fetch('failure_count')
21
+ errors = summary.fetch('errors_outside_of_examples_count')
22
+ executed = total - pending
23
+
24
+ puts format(
25
+ 'examples=%d executed=%d failures=%d pending=%d errors_outside_examples=%d',
26
+ total, executed, failures, pending, errors
27
+ )
28
+
29
+ problems = []
30
+ problems << "#{errors} error(s) outside of examples" if errors.positive?
31
+ if executed < MIN_EXAMPLES
32
+ problems << "only #{executed} example(s) executed, expected at least #{MIN_EXAMPLES}"
33
+ end
34
+
35
+ unless problems.empty?
36
+ warn "FAIL: #{problems.join('; ')}"
37
+ exit 1
38
+ end
39
+
40
+ puts "OK: suite executed #{executed} examples"
@@ -0,0 +1,42 @@
1
+ name: CI
2
+
3
+ on:
4
+ pull_request:
5
+ push:
6
+ branches: [master]
7
+
8
+ permissions:
9
+ contents: read
10
+
11
+ jobs:
12
+ spec:
13
+ name: rspec (ruby ${{ matrix.ruby }})
14
+ runs-on: ubuntu-latest
15
+ strategy:
16
+ fail-fast: false
17
+ matrix:
18
+ # 3.4 was excluded while the published paubox gem required base64
19
+ # without declaring it, which fails to load on 3.4 since base64 left
20
+ # the default gems there. paubox 1.0.0 declares base64 and ostruct, and
21
+ # this gem now requires '~> 1.0', so 3.4 is back.
22
+ ruby: ["3.1", "3.2", "3.3", "3.4"]
23
+
24
+ steps:
25
+ - uses: actions/checkout@v4
26
+
27
+ - uses: ruby/setup-ruby@v1
28
+ with:
29
+ ruby-version: ${{ matrix.ruby }}
30
+ bundler-cache: true
31
+
32
+ - name: Run specs
33
+ # Both formatters are explicit: a CLI --format overrides the one in
34
+ # .rspec, so without this the log would be empty on failure. The JSON
35
+ # file feeds the gate below.
36
+ run: >-
37
+ bundle exec rspec
38
+ --format documentation
39
+ --format json --out rspec-results.json
40
+
41
+ - name: Assert the suite actually executed
42
+ run: ruby .github/scripts/assert_specs_ran.rb rspec-results.json
@@ -0,0 +1,36 @@
1
+ name: PR Title
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [master, main]
6
+ types: [opened, edited, reopened, synchronize]
7
+
8
+ permissions:
9
+ contents: read
10
+
11
+ jobs:
12
+ conventional-title:
13
+ name: Conventional commit title
14
+ runs-on: ubuntu-latest
15
+ steps:
16
+ # With squash merging the squash commit subject is the PR title, so this
17
+ # string is all release-please ever parses. A title it cannot parse is
18
+ # silently dropped from the release rather than failing anything, so it is
19
+ # gated here instead.
20
+ - uses: amannn/action-semantic-pull-request@v6
21
+ env:
22
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23
+ with:
24
+ types: |
25
+ feat
26
+ fix
27
+ perf
28
+ revert
29
+ docs
30
+ style
31
+ refactor
32
+ test
33
+ build
34
+ ci
35
+ chore
36
+ deps
@@ -0,0 +1,88 @@
1
+ name: release-please
2
+
3
+ on:
4
+ push:
5
+ branches: [master]
6
+
7
+ permissions:
8
+ contents: write
9
+ pull-requests: write
10
+
11
+ jobs:
12
+ release-please:
13
+ name: Release Please
14
+ runs-on: ubuntu-latest
15
+ outputs:
16
+ release_created: ${{ steps.release.outputs.release_created }}
17
+ tag_name: ${{ steps.release.outputs.tag_name }}
18
+ steps:
19
+ # Maintains a release PR that bumps VERSION in
20
+ # lib/paubox_rails/version.rb and writes CHANGELOG.md. Merging that PR
21
+ # creates the tag and the GitHub release, which gates the publish below.
22
+ #
23
+ # The manifest is seeded from RubyGems (0.1.6), not from version.rb, which
24
+ # had drifted to 0.3.0. Neither 0.2.0 nor 0.3.0 was ever pushed, so
25
+ # seeding from the repo would have skipped two unused numbers.
26
+ #
27
+ # include-component-in-tag is false so tags stay bare `vX.Y.Z`, matching
28
+ # v0.1.6 and the rest of the SDK fleet.
29
+ - uses: googleapis/release-please-action@v4
30
+ id: release
31
+ with:
32
+ token: ${{ secrets.GITHUB_TOKEN }}
33
+ config-file: release-please-config.json
34
+ manifest-file: .release-please-manifest.json
35
+
36
+ publish:
37
+ name: Publish ${{ needs.release-please.outputs.tag_name }} to RubyGems
38
+ needs: release-please
39
+ if: needs.release-please.outputs.release_created == 'true'
40
+ runs-on: ubuntu-latest
41
+ permissions:
42
+ contents: read
43
+ # Required for OIDC. Without it the credentials step cannot identify
44
+ # itself to RubyGems.org and the push fails.
45
+ id-token: write
46
+ steps:
47
+ - uses: actions/checkout@v4
48
+ with:
49
+ ref: ${{ needs.release-please.outputs.tag_name }}
50
+ # The gemspec builds its file list from `git ls-files`, so the
51
+ # checkout has to keep the repository intact.
52
+ persist-credentials: false
53
+
54
+ - uses: ruby/setup-ruby@v1
55
+ with:
56
+ ruby-version: '3.4'
57
+ bundler-cache: true
58
+
59
+ - name: Run specs
60
+ run: bundle exec rspec --format documentation
61
+
62
+ - name: Verify the tag and version.rb agree
63
+ # Cheap guard against pushing a gem whose version does not match the
64
+ # tag it was cut from. RubyGems only allows a yank within 72 hours and
65
+ # never allows the number to be reused.
66
+ env:
67
+ RELEASE_TAG: ${{ needs.release-please.outputs.tag_name }}
68
+ run: |
69
+ GEM_VERSION=$(ruby -Ilib -e 'require "paubox_rails/version"; print PauboxRails::VERSION')
70
+ if [ "v${GEM_VERSION}" != "${RELEASE_TAG}" ]; then
71
+ echo "::error::version.rb is ${GEM_VERSION} but the tag is ${RELEASE_TAG}"
72
+ exit 1
73
+ fi
74
+ echo "version.rb ${GEM_VERSION} matches ${RELEASE_TAG}"
75
+
76
+ - name: Build the gem
77
+ run: gem build paubox_rails.gemspec
78
+
79
+ # Trusted publishing: exchanges GitHub's OIDC token for a short-lived
80
+ # RubyGems credential. There is no API key stored anywhere. RubyGems pins
81
+ # the trust to the repository and this workflow filename, so renaming
82
+ # this file breaks publishing until the trusted publisher entry for the
83
+ # `paubox_rails` gem is updated to match.
84
+ - name: Configure RubyGems credentials
85
+ uses: rubygems/configure-rubygems-credentials@main
86
+
87
+ - name: Push the gem
88
+ run: gem push paubox_rails-*.gem
data/.gitignore CHANGED
@@ -10,4 +10,7 @@
10
10
 
11
11
  # rspec failure tracking
12
12
  .rspec_status
13
- *.gem
13
+ *.gem
14
+
15
+ # rspec JSON output written by CI.
16
+ rspec-results.json
@@ -0,0 +1,3 @@
1
+ {
2
+ ".": "1.0.0"
3
+ }
data/CHANGELOG.md ADDED
@@ -0,0 +1,69 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ ## [1.0.0](https://github.com/Paubox/paubox-rails/compare/v0.1.6...v1.0.0) (2026-08-21)
6
+
7
+ First stable release. RubyGems had been on `0.1.6` since September 2021.
8
+
9
+ ### ⚠ BREAKING CHANGES
10
+
11
+ - Requires `paubox ~> 1.0` ([#17](https://github.com/Paubox/paubox-rails/pull/17)). The previous constraint was `~> 0.3`, which resolves to `< 1.0` and could not pick up [`paubox` 1.0.0](https://rubygems.org/gems/paubox/versions/1.0.0). Applications pinning `paubox` to a 0.x version must upgrade it alongside this gem
12
+
13
+ ### 🚀 New Features
14
+
15
+ - Add `PauboxRails::Forms::Client` for the Paubox Forms API
16
+ - Public endpoints, no credential attached: `get_form`, `submit_form`
17
+ - Form management with a scoped API key (`forms` scope, read from `PAUBOX_FORMS_API_KEY` or passed to the constructor, sent as a Bearer token): `list_forms`, `create_form`, `get_form_details`, `update_form`, `archive_form`, `unarchive_form`, `copy_form`, `form_stats`
18
+ - Submissions: `list_submissions`, `submissions_csv`, `submission_pdf`
19
+ - The Email API no longer requires a username — an API key alone authenticates
20
+
21
+ ### ⚠️ Behavior Changes
22
+
23
+ - Base URLs move to `api.paubox.com`
24
+
25
+ ### 🔒 Hardening
26
+
27
+ - Validate and encode caller-supplied values interpolated into Forms request paths. Authenticated endpoints require a UUID; public endpoints encode the segment instead of rejecting it
28
+
29
+ ### 🎉 Enhancements
30
+
31
+ - Relicense from MIT to Apache 2.0, matching the rest of the Paubox SDKs
32
+ - Replace the dead Travis config with a GitHub Actions CI workflow, now covering Ruby 3.1 through 3.4 ([51c3714](https://github.com/Paubox/paubox-rails/commit/51c3714d32bd2ed29c5c07a7a1d073719b58dbec))
33
+
34
+ ## v0.1.6 / 2021-09-27
35
+
36
+ ### 🎉 Enhancements
37
+
38
+ - Remove the upper bound on the `actionmailer` dependency
39
+ - Update the `rake` development dependency
40
+
41
+ ## v0.1.4 / 2019-07-10
42
+
43
+ ### 🎉 Enhancements
44
+
45
+ - Require `paubox ~> 0.3`
46
+
47
+ ## v0.1.3 / 2018-10-04
48
+
49
+ ### 🎉 Enhancements
50
+
51
+ - Widen the supported `actionmailer` range
52
+
53
+ ## v0.1.2 / 2018-10-04
54
+
55
+ ### 🎉 Enhancements
56
+
57
+ - Require `paubox ~> 0.2`
58
+
59
+ ## v0.1.1 / 2018-07-25
60
+
61
+ ### 🎉 Enhancements
62
+
63
+ - Constrain `actionmailer` to the versions then supported
64
+
65
+ ## v0.1.0 / 2018-04-26
66
+
67
+ ### 🚀 Major Release
68
+
69
+ First release of the Paubox Transactional Email adapter for ActionMailer.
data/CLAUDE.md ADDED
@@ -0,0 +1,93 @@
1
+ # CLAUDE.md — paubox-rails codebase guide
2
+
3
+ ## What this gem does
4
+
5
+ `paubox-rails` is a thin Rails adapter gem with two responsibilities:
6
+
7
+ 1. **Email delivery** — Registers `:paubox` as an ActionMailer delivery method, delegating all sending to the [`paubox`](https://github.com/paubox/paubox_ruby) gem (`Mail::Paubox`).
8
+ 2. **Forms API client** — Provides `PauboxRails::Forms::Client` for interacting with the Paubox Forms API: public respondent endpoints (`get_form`, `submit_form` — no auth) plus authenticated form-management endpoints (list/create/update/archive/copy forms, stats, submissions, CSV/PDF export) that require a scoped API key with the `forms` scope, sent as `Authorization: Bearer`.
9
+
10
+ ## Key files
11
+
12
+ ```
13
+ lib/
14
+ paubox_rails.rb # Entry point: requires all components, registers delivery method
15
+ paubox_rails/
16
+ version.rb # VERSION constant
17
+ railtie.rb # Rails hook — registers delivery method before ActionMailer boots
18
+ forms.rb # PauboxRails::Forms module: BASE_URL, error classes, .client factory
19
+ forms/
20
+ client.rb # Forms HTTP client (Net::HTTP, no extra deps)
21
+ spec/
22
+ paubox_rails_spec.rb # Integration tests for ActionMailer delivery
23
+ paubox_rails/
24
+ forms/
25
+ client_spec.rb # Unit tests for Forms::Client (Net::HTTP stubs)
26
+ fixtures/
27
+ models/test_mailer.rb # Minimal ActionMailer subclass used in tests
28
+ views/test_mailer/ # ERB template for the test mailer
29
+ ```
30
+
31
+ ## Architecture
32
+
33
+ ```
34
+ paubox-rails
35
+ ├── Email path
36
+ │ ActionMailer → Mail::Paubox (from paubox gem) → RestClient → api.paubox.com
37
+ └── Forms path
38
+ PauboxRails::Forms::Client → Net::HTTP → api.paubox.com/forms
39
+ ```
40
+
41
+ - Email credentials (`api_key`) are configured via `Paubox.configure`.
42
+ - Forms **respondent endpoints** (`get_form`, `submit_form`) are public — no credentials needed. All other Forms endpoints require a scoped API key (`forms` scope), passed via `Forms.client(api_key: ...)` or the `PAUBOX_FORMS_API_KEY` env var.
43
+
44
+ ## Running tests
45
+
46
+ ```bash
47
+ bundle install
48
+ bundle exec rspec
49
+ ```
50
+
51
+ ## How to add a new Forms endpoint
52
+
53
+ 1. Add a method to `lib/paubox_rails/forms/client.rb` following the `get_form` / `submit_form` pattern.
54
+ 2. Use `build_http(uri)` to get an SSL-ready `Net::HTTP` instance.
55
+ 3. Call `handle_response(response)` for consistent error handling.
56
+ 4. Add corresponding tests in `spec/paubox_rails/forms/client_spec.rb`, stubbing `Net::HTTP.new` via `instance_double`.
57
+ 5. Document the new method in `api.md` and `README.md`.
58
+
59
+ ## How to add a new email feature
60
+
61
+ Email functionality lives in the `paubox` gem (not here). This gem only bridges ActionMailer to `Mail::Paubox`. To add email features, update the `paubox` gem and bump its version constraint in `paubox_rails.gemspec`.
62
+
63
+ ## Version
64
+
65
+ Current: `0.3.0` (in `lib/paubox_rails/version.rb`)
66
+
67
+ - `0.1.x` — Initial releases, email delivery only
68
+ - `0.2.0` — Added Paubox Forms API support (public respondent endpoints)
69
+ - `0.3.0` — Full Forms API support, including scoped-API-key (authenticated) management endpoints
70
+
71
+ ## Releases
72
+
73
+ Releases are automated with [release-please](https://github.com/googleapis/release-please). Merging to `master` refreshes a standing release PR; merging *that* PR bumps `lib/paubox_rails/version.rb`, writes `CHANGELOG.md`, creates a bare `vX.Y.Z` tag and a GitHub release, and then **pushes the gem to RubyGems**.
74
+
75
+ Do **not** hand-edit `VERSION` or add a `CHANGELOG.md` entry — release-please owns both.
76
+
77
+ The next version comes from PR titles: `feat:` gives a minor bump, `fix:` a patch, and a `!` suffix or a `BREAKING CHANGE:` footer gives a major. `.github/workflows/pr-title.yml` rejects titles release-please cannot parse.
78
+
79
+ To force a specific version, land an empty commit with a `Release-As` footer. Put the notes in the subject and footers — release-please renders those but not the commit body:
80
+
81
+ ```bash
82
+ git commit --allow-empty -m "chore: release 1.0.0" -m "Release-As: 1.0.0"
83
+ ```
84
+
85
+ ### Publishing
86
+
87
+ Publishing uses RubyGems **trusted publishing** (OIDC) — no API key is stored. RubyGems pins the trust to the repository and the workflow filename, so **renaming `release-please.yml` breaks publishing** until the trusted publisher entry for the `paubox_rails` gem is updated.
88
+
89
+ Version numbers on RubyGems are effectively permanent — a yank is only possible within 72 hours and never frees the number for reuse.
90
+
91
+ ### Relationship to the `paubox` gem
92
+
93
+ This gem depends on `paubox` and the gemspec constraint has to allow whatever major version is current there. When `paubox` takes a major bump, this gem needs a matching release that widens the constraint — otherwise Bundler silently holds users on the older `paubox` with no error. Release `paubox` first, then this gem.
data/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for describing the origin of the Work and
141
+ reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may accept and charge a
167
+ fee for, acceptance of support, warranty, indemnity, or other
168
+ liability obligations and/or rights consistent with this License.
169
+ However, in accepting such obligations, You may act only on Your
170
+ own behalf and on Your sole responsibility, not on behalf of any
171
+ other Contributor, and only if You agree to indemnify, defend,
172
+ and hold each Contributor harmless for any liability incurred by,
173
+ or claims asserted against, such Contributor by reason of your
174
+ accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2026 Paubox, Inc.
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.