Enable a gateway for one country
Adds one country to the gateway’s coverage without touching the rest of
its list, so two admins seeding different countries never overwrite each
other. The link is judged against the account’s membership rules before
it is written: no second active non-card account of the same integration
type and recurring mode on the country (one regular and one
recurring-only PayPal account may share a country), and no live and test
card gateway on one country.
Linking a country the gateway already serves is a no-op that returns
200. Every link is recorded on the gateway’s audit trail with the
acting admin, or the merchant when an API key made the call.
On this operation a droplet token receives 403 and a JWT needs root
admin or an explicit gateways.update or apm.update role grant; the
gateway create and update operations keep their own authorization.
Returns 404 for an unknown gateway or a country the company has not
enabled, and 422 when a membership rule refuses the link or the
country code is not a two-letter ISO 3166-1 code.
Authorizations
Merchant API key (fp_live_* for live, fp_test_* for sandbox) or an
admin-tier JWT (company admin or root admin). Non-admin JWTs are
rejected with 403; live API keys additionally require the merchant's
API access to be enabled.
Path Parameters
Gateway slug, UUID, or ID
Body
ISO 3166-1 alpha-2 code of the country to enable.
2^[A-Za-z]{2}$