Contributing Verified Provider Fixtures (docs/CONTRIBUTING-FIXTURES.md)
dz-sandbox refuses to fabricate API specifications. Whenever an endpoint or error code lacks a real source, it stays tagged unverified in SPEC_STATUS.md. Contributing sanitized captures from real sandbox/test accounts is the single highest-impact way to help upgrade dz-sandbox fidelity.
1. Fixture Types & Directory Layout
fixtures/
chargily/captured/ # Contributed HTTP request/response JSON captures (verified: true)
satim/captured/
yalidine/captured/
zrexpress/captured/
maystro/captured/
openapi-demo/ # Experimental handwritten OpenAPI 3.x samples
Every contributed capture JSON must validate against CapturedExchangeSchema and include:
provider:"chargily" | "satim" | "yalidine" | "zrexpress" | "maystro"verified:true(only for real provider test/sandbox HTTP captures)source:"captured YYYY-MM-DD"(plus ticket/doc reference if public)captureDate: ISOYYYY-MM-DDupstreamHost: upstream hostname (no credentials)request:{ method, path, query, headers, body }response:{ status, headers, body }
2. Capture Safely Using dz-sandbox record
- Start the local recording proxy with mandatory default redaction:
``bash npx dz-sandbox record --provider chargily --upstream https://pay.chargily.net/test/api/v2 --out ./fixtures/chargily/captured ``
- Point your integration script at
http://127.0.0.1:4100instead of the live URL, execute the flow (success + validation/failure cases), then pressCtrl+C. - Never pass
--no-redactfor PR submissions —dz-sandboxrefuses to write unredacted captures insidefixtures/.
3. Mandatory Privacy & Secret Hygiene Checklist
Before opening your PR, verify all items below and run the automated validator:
npx dz-sandbox fixtures validate ./fixtures
- [ ] No live or test secret keys (
sk_live_*,test_sk_*,Bearer ...,X-API-TOKEN, SATIMuserName/password) appear anywhere. - [ ] No real customer emails, real Algerian phone numbers (
05/06/07/+213), real full names, or street addresses appear (use<REDACTED_EMAIL_*>,<REDACTED_PHONE_*>, or RFC example domainsexample.com). - [ ] No PAN / card numbers (
13–19digits), CVV, OTP, or bank RIB/RIP/CCP numbers appear. - [ ] Sensitive request/response headers (
Authorization,Cookie,Set-Cookie) are stripped by the header allowlist. - [ ] Update
SPEC_STATUS.mdin the same PR, citing yoursourcecapture filename and date for each upgraded endpoint.