List the bank rules governing a company
GET/api/v1/workspaces/:workspace_id/companies/:company_id/bank_rules
Returns the rules that GOVERN this company: its own company-scoped rules AND the workspace rules it is not excluded from. The workspace rules are included on purpose - they bind this company's operations and are named in the explanation the PREVIEW publishes, so a list without them could not explain an imputation. Disabled rules are listed too; use enabled to filter.
Request
Responses
- 200
- 400
- 401
- 403
- 404
The rules governing the company.
page is past the last page of a non-empty set, or is not a positive integer. STOP AT meta.total_pages rather than paging until data comes back empty: on a non-empty collection the page after the last one is THIS refusal, not an empty page. An EMPTY collection is the other case and behaves differently - it answers 200 with an empty data on every page, because it has no last page to be past.
The request carries no bearer token, or one that is invalid or expired. doorkeeper_authorize! is the first gate of the chain, so this is answered before the workspace, the company, the feature flag and the record are ever resolved - and before any Idempotency-Key is claimed.
The token holds no grant for this workspace, or no such workspace exists.
No company with this id belongs to the resolved workspace. A company of another workspace answers the same way, so the response cannot be used to probe for one.