@delopay/sdk 0.123.0 → 0.124.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.
- package/dist/{chunk-JQXBXZ2L.js → chunk-4TVKPQTZ.js} +27 -1
- package/dist/chunk-4TVKPQTZ.js.map +1 -0
- package/dist/index.cjs +26 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +138 -1
- package/dist/index.d.ts +138 -1
- package/dist/index.js +1 -1
- package/dist/internal.cjs +26 -0
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.d.cts +1 -1
- package/dist/internal.d.ts +1 -1
- package/dist/internal.js +1 -1
- package/package.json +17 -18
- package/dist/chunk-JQXBXZ2L.js.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -797,6 +797,32 @@ var Connectors = class {
|
|
|
797
797
|
{ body: params }
|
|
798
798
|
);
|
|
799
799
|
}
|
|
800
|
+
/**
|
|
801
|
+
* What the processor says about this connector account: whether it will
|
|
802
|
+
* accept charges, which capabilities are live, and anything it is still
|
|
803
|
+
* waiting on.
|
|
804
|
+
*
|
|
805
|
+
* This is **not** {@link Connectors.verify}. That one asks whether the stored
|
|
806
|
+
* credentials work, by running a test-card authorization; a processor can
|
|
807
|
+
* revoke an account's ability to take payments while the credentials stay
|
|
808
|
+
* perfectly valid, and then a credential check reports healthy while every
|
|
809
|
+
* checkout silently stalls. This asks the account's own status instead, and
|
|
810
|
+
* is a plain read — it costs the merchant nothing and is safe to call twice.
|
|
811
|
+
*
|
|
812
|
+
* Connectors with no probe answer `state: 'unknown'` with
|
|
813
|
+
* `unknown_reason: 'connector_not_supported'`, rather than an error — every
|
|
814
|
+
* `'unknown'` carries a reason code you render your own words for. A router
|
|
815
|
+
* without this endpoint answers 404 — render that as "this build cannot
|
|
816
|
+
* report health", never as "healthy".
|
|
817
|
+
*
|
|
818
|
+
* `GET /account/{accountId}/connectors/{connectorId}/health`
|
|
819
|
+
*/
|
|
820
|
+
async health(accountId, connectorId) {
|
|
821
|
+
return this.request(
|
|
822
|
+
"GET",
|
|
823
|
+
`/account/${encodeURIComponent(accountId)}/connectors/${encodeURIComponent(connectorId)}/health`
|
|
824
|
+
);
|
|
825
|
+
}
|
|
800
826
|
/** Verify connector credentials. `POST /account/connectors/verify` */
|
|
801
827
|
async verify(params) {
|
|
802
828
|
return this.request("POST", "/account/connectors/verify", { body: params });
|