The sandbox is a separate copy of InStockRx at sandbox.instockrx.com, with its own database, its own user accounts and simulated payments. Every API call that works in production, writes included, works here, and nothing you do moves real money or reaches a real pharmacy. You sign yourself up, InStockRx approves the request, and you get a working setup — a group, two test pharmacies that can trade with each other, and your API keys — with nothing to configure.
Sandbox and production are separate. A production login does not work on the sandbox and a sandbox login does not work in production. API keys are per environment in the same way.

Before you start

  • An email address you can read. Activation and invitation links are sent by email, and it becomes the address InStockRx associates with your company.
  • Your company name, and optionally its website.
  • A short description of what you plan to build.
  • Which API versions you want: V1, V2 or both.

Getting access

1

Create a sandbox account

Open sandbox.instockrx.com and create an account. The sandbox terms are accepted as part of sign-up. Use the email address you want associated with your company: every link is sent there.
2

Request sandbox access

After your first sign-in you land on Home and a Request sandbox access dialog opens:
  • Company name (required)
  • Company website (optional; must start with http:// or https://)
  • What do you plan to build? (required)
  • Which API versions do you plan to use? V2 is pre-selected; tick V1 as well if you need it. At least one is required.
Your name and email come from your account. Press Submit request. If you close the dialog, Home shows the same request as a card with a Request access button.Until your access is activated, Home is the only page available.
3

Wait for review

Home shows Your request is under review and checks for changes on its own. InStockRx reviews every request by hand.
  • Approved: Home shows Your request is approved with the date the activation link is valid until, and the activation email is sent to you.
  • Not approved: Home shows the reviewer’s note, which is also emailed to you. Press Request again to send a new request with more detail.
4

Activate your access

Open the link in the approval email (https://sandbox.instockrx.com/developers/activate?token=…). If you are not signed in, you sign in first and come back to the page. Sign in with the address the email was sent to.The page reads Join the your company sandbox: you become the owner of the organization, and your starter kit is built right after activation. Press Activate access.
The link works once and expires 72 hours after it was sent. A used link, or one opened while signed in with a different email, shows This activation link is not valid any more. An expired one shows This activation link has expired. Ask InStockRx to resend it: the new link replaces the old one, which stops working.

Your starter kit

Right after activation InStockRx builds a complete test setup for your company in the background. For a company called Acme, it contains: Each test pharmacy carries a real pharmacy NPI taken from the NPI Registry, so NPI-based calls behave as they do in production. The pharmacy it belongs to is elsewhere in the US and has nothing to do with your test pharmacy. Names, addresses, licences and compliance documents are placeholders. Both pharmacies are cold-chain certified and have no compliance prompts to clear. Home shows the kit status next to your company name and refreshes it every few seconds: Not started → Provisioning → Ready. Setting up payments is the slow part, so expect minutes rather than seconds. When it is Ready, the tabs on Home fill in, both pharmacies appear in your pharmacy selector, and you receive a “kit ready” email (it never contains key material). If the build fails, the status reads Failed and Home shows the reason, followed by InStockRx has been notified. Staff retry the build, and the retry resumes after the last step that finished. Home stops refreshing after a failure, so reload the page to see the result of the retry. Issuing V2 keys, inviting teammates and resetting data become available once the kit is Ready.

Your Home page

Home is at https://sandbox.instockrx.com/developers/home. The header shows your company, the kit status, your role and email, your group, an API documentation link and the Reset sandbox data button.

Overview

  • Base URLs for V1 and V2, with copy buttons. The sandbox API is https://sandbox-api.instockrx.com.
  • Pharmacies: each test pharmacy’s name, Seller or Buyer, NPI, a Charges enabled or Charges pending chip, and its id with a copy button. V2 calls name the pharmacy you act as by this id, in X-Pharmacy-Id; V1 calls name it by NPI.
  • Forced responses for testing, sent as the X-InStockRx-Trigger header on a V2 call: The header is ignored in production.

API keys

V1 key. One key shared by everyone in your organization. Anyone can reveal and copy it. Only the owner can Regenerate it: a new key is issued, and the old one is refused on some requests at once and everywhere within 60 seconds. Tell your teammates before you do it. V2 keys. Personal keys with full access, starting ik_sandbox_. Each person can hold at most two active keys they issued; the starter key counts as the owner’s. The tab shows n of 2 of your keys, and teammates’ keys do not count against you.
The Rotate confirmation is wrong about the old key. It says the current key stops working once the new one is issued. It doesn’t: the old key keeps working for up to one hour after you rotate, as described above. Plan your switch-over around the hour, and revoke the old key yourself if you need it gone sooner.
The owner can rotate or revoke any key. A member can rotate or revoke only the keys they issued; on anyone else’s the buttons are disabled with Only the key’s issuer can do this.

Team

Lists everyone in your organization: name, email, Owner or Member, status, who invited them and, for pending invitations, when the invitation expires. The owner can Invite (email and name), Resend a pending invitation and Remove people. Members see the list read-only. An invited teammate:
  1. Receives an email with a link and its expiry date.
  2. Creates a sandbox account with that same email address, or signs in if they already have one.
  3. Opens the link and presses Activate access. The page names who invited them. No request form is needed: the invitation places them in your organization.
Invitation links follow the same rules as activation links: single use, 72 hours, and a resend replaces the old link. An email that already has a request, or sandbox access in another organization, is refused with There is already a request or account for this email. Removing a teammate takes away their sandbox access and revokes the V2 keys they issued. Your keys, other members’ keys and the shared V1 key are not affected. The removed person keeps their sandbox login, is told by email, and can be invited again or request access of their own. You cannot remove yourself, or a teammate InStockRx has suspended.

Resetting sandbox data

Reset sandbox data puts your test pharmacies back to how they were right after onboarding, so you can re-run integration tests from a clean start.

What goes

  • Pending listings sold by your pharmacies are cancelled (“Sandbox data reset”), with a marketplace_listing.cancelled webhook event for each.
  • Pending cash offers your pharmacies made are cancelled, with a cash_offer.cancelled event for each.
  • Draft listings are deleted, images included.
  • Evergreen cash-offer preferences are deleted.
  • The pharmacies get their starter names and addresses back.

What stays

  • Anything past pending: completed and in-flight transactions.
  • Your group, both pharmacies, the V1 key, every V2 key and every webhook endpoint.
  • Cash offers other organizations made to your pharmacies.
  • Blacklists, NDC restrictions, favorites and shipping preferences.
  • Only the owner can reset, once the kit is Ready.
  • One reset every 10 minutes, counted from the moment you confirm. Until then the button is disabled; hover over it to see when the next reset is allowed.
  • After you confirm, Reset started. Your data is cleared in the background. appears. The page itself does not change; the data is cleared within a few seconds. A listing or offer that stopped being pending in the meantime, for example because it was bought, is left alone.

Roles

An organization has exactly one owner. InStockRx staff can promote a member to owner; the previous owner then becomes a member. No purchase limits are set for anyone when they join.

What else is in the sandbox

The marketplace is not empty. Every day the 100 newest pending listings and cash offers from production are copied into the sandbox and attached to demo pharmacies, so searches return realistic NDCs and prices. They are sandbox records: buying one is simulated like everything else here, and nothing reaches the production pharmacy that posted the original.

What the sandbox does not have

  • Messages. In-app chat between pharmacies is switched off. Chat is not part of the public API, so there is nothing to test there.
  • Your own pharmacies. There is no “Add a pharmacy”; use the two from your starter kit.
  • Real money. Purchases, payouts, refunds and fees behave as in production but never move funds.

Suspension

InStockRx can suspend a person or a whole organization. Everyone affected is told by email, with the reviewer’s note if there is one.

Getting help

For anything about your access — a lost or expired activation link, a failed starter kit, a suspension — email info@instockrx.com.

Next

Make your first call

Copy the V1 key from the API keys tab and list your test pharmacies.

Moving to production

Production keys are issued by InStockRx, not from the sandbox.