Documents

Bizzy Pre Check - Postman Collection

JSON
{
"info": {
"_postman_id": "d52a1c6a-c18d-489f-b573-34d409d81e5a",
"name": "Bizzy Pre-Check API",
"description": "Check which funding options across the Bizzy lender panel a New Zealand business could be eligible for.\n\n**Authentication:** none.\n\n**Rate limits:** 10 requests per minute and 200 requests per day per IP address. Every request in this collection counts towards them. Over either limit the API returns `429 Too Many Requests`, and `detail` says how many seconds to wait.\n\nSet the `nzbn` collection variable to try a different business.",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
},
"item": [
{
"name": "Eligibility",
"description": "`POST /api/v1/pre-check/eligibility`",
"item": [
{
"name": "Eligible business",
"event": [
{
"listen": "test",
"script": {
"type": "text/javascript",
"exec": [
"pm.test(\"Status is 200\", () => pm.response.to.have.status(200));",
"const body = pm.response.json();",
"pm.test(\"eligible is a boolean\", () => pm.expect(body.eligible).to.be.a(\"boolean\"));",
"pm.test(\"products is an array\", () => pm.expect(body.products).to.be.an(\"array\"));",
"pm.test(\"products is empty only when not eligible\", () => pm.expect(body.products.length > 0).to.eql(body.eligible));"
]
}
}
],
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"{{nzbn}}\",\n \"monthly_turnover\": 12500,\n \"trading_months\": 18,\n \"invoices_owed\": true\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "A registered, active business with turnover and trading history that qualify for all three funding options."
},
"response": [
{
"name": "200 OK",
"originalRequest": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"{{nzbn}}\",\n \"monthly_turnover\": 12500,\n \"trading_months\": 18,\n \"invoices_owed\": true\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "A registered, active business with turnover and trading history that qualify for all three funding options."
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": "{\n \"eligible\": true,\n \"products\": [\n \"UNSECURED\",\n \"LINE_OF_CREDIT\",\n \"INVOICE_FINANCING\"\n ]\n}"
}
]
},
{
"name": "Not eligible (turnover too low)",
"event": [
{
"listen": "test",
"script": {
"type": "text/javascript",
"exec": [
"pm.test(\"Status is 200\", () => pm.response.to.have.status(200));",
"const body = pm.response.json();",
"pm.test(\"Not eligible\", () => pm.expect(body.eligible).to.be.false);",
"pm.test(\"No products\", () => pm.expect(body.products).to.be.empty);"
]
}
}
],
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"{{nzbn}}\",\n \"monthly_turnover\": 1000,\n \"trading_months\": 18,\n \"invoices_owed\": false\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "The same business with a monthly turnover below every funding option's minimum. The response is still 200, with `eligible: false` and no funding options."
},
"response": [
{
"name": "200 OK",
"originalRequest": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"{{nzbn}}\",\n \"monthly_turnover\": 1000,\n \"trading_months\": 18,\n \"invoices_owed\": false\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "The same business with a monthly turnover below every funding option's minimum. The response is still 200, with `eligible: false` and no funding options."
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": "{\n \"eligible\": false,\n \"products\": []\n}"
}
]
},
{
"name": "Invalid NZBN",
"event": [
{
"listen": "test",
"script": {
"type": "text/javascript",
"exec": [
"pm.test(\"Status is 400 or 422\", () => pm.expect(pm.response.code).to.be.oneOf([400, 422]));",
"pm.test(\"NzbnInvalidException returned\", () => pm.expect(pm.response.json().errors).to.have.property(\"NzbnInvalidException\"));"
]
}
}
],
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"9429046277003\",\n \"monthly_turnover\": 12500\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "The NZBN register rejects an NZBN that isn't valid. The response is 400 (or 422) with `errors.NzbnInvalidException`."
},
"response": [
{
"name": "400 Bad Request",
"originalRequest": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"9429046277003\",\n \"monthly_turnover\": 12500\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "The NZBN register rejects an NZBN that isn't valid. The response is 400 (or 422) with `errors.NzbnInvalidException`."
},
"status": "Bad Request",
"code": 400,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": "{\n \"success\": false,\n \"message\": \"\",\n \"errors\": {\n \"NzbnInvalidException\": \"The NZBN register rejected the NZBN as invalid\"\n }\n}"
}
]
},
{
"name": "Validation error (negative turnover)",
"event": [
{
"listen": "test",
"script": {
"type": "text/javascript",
"exec": [
"pm.test(\"Status is 422\", () => pm.response.to.have.status(422));",
"pm.test(\"Errors listed\", () => pm.expect(pm.response.json()).to.be.an(\"array\").that.is.not.empty);"
]
}
}
],
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"{{nzbn}}\",\n \"monthly_turnover\": -100\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "A request body that fails validation returns 422 with a list of errors. Each error's `loc` names the field."
},
"response": [
{
"name": "422 Unprocessable Entity",
"originalRequest": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/api/v1/pre-check/eligibility",
"host": [
"{{baseUrl}}"
],
"path": [
"api",
"v1",
"pre-check",
"eligibility"
]
},
"body": {
"mode": "raw",
"raw": "{\n \"nzbn\": \"{{nzbn}}\",\n \"monthly_turnover\": -100\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"description": "A request body that fails validation returns 422 with a list of errors. Each error's `loc` names the field."
},
"status": "Unprocessable Entity",
"code": 422,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": "[\n {\n \"type\": \"greater_than_equal\",\n \"loc\": [\n \"body\",\n \"payload\",\n \"monthly_turnover\"\n ],\n \"msg\": \"Input should be greater than or equal to 0\"\n }\n]"
}
]
}
]
}
],
"variable": [
{
"key": "baseUrl",
"value": "https://app.bizzyhub.co",
"type": "string"
},
{
"key": "nzbn",
"value": "9429041547977",
"type": "string"
}
]
}

Bizzy Pre Check - Open API

JSON
{
"openapi": "3.1.0",
"info": {
"title": "Bizzy Pre-Check API",
"version": "1.0.0",
"description": "Check which funding options across the Bizzy lender panel a New Zealand business could be eligible for.\n\n**Authentication:** none. Access is limited by rate.\n\n**Rate limits:** 10 requests per minute and 200 requests per day per client IP address. Requests over either limit receive `429 Too Many Requests`.\n"
},
"servers": [
{
"url": "https://app.bizzyhub.co"
}
],
"tags": [
{
"name": "Pre-Check"
}
],
"paths": {
"/api/v1/pre-check/eligibility": {
"post": {
"operationId": "pre-check-eligibility",
"summary": "Check funding eligibility",
"parameters": [],
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PreCheckOut"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorsOut"
}
}
}
},
"422": {
"description": "Unprocessable Entity",
"content": {
"application/json": {
"schema": {
"anyOf": [
{
"$ref": "#/components/schemas/ErrorsOut"
},
{
"items": {
"$ref": "#/components/schemas/PreCheckValidationError"
},
"type": "array"
}
],
"title": "Response"
}
}
}
},
"429": {
"description": "Too Many Requests",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PreCheckThrottledOut"
}
}
}
},
"503": {
"description": "Service Unavailable",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorsOut"
}
}
}
}
},
"description": "Check which funding options across the Bizzy lender panel a New Zealand business could be eligible for,\nbefore it signs up.\n\nSend the business's NZBN, average monthly turnover, how long it has been trading and whether it has\ninvoices owed to it. The response says whether the business is eligible and lists the codes of the\nfunding options it could qualify for.\n\n**Errors**\n- `400` / `422` with `errors.NzbnInvalidException`: the NZBN isn't valid.\n- `422` with a list of validation errors: the request body is invalid, e.g. a negative turnover.\n- `429`: the rate limit was exceeded. `detail` says how many seconds until the next request is allowed.\n- `503` with `errors.NzbnUnavailableException`: the NZBN register is unavailable. Retry later.",
"tags": [
"Pre-Check"
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PreCheckIn"
}
}
},
"required": true
}
}
}
},
"components": {
"schemas": {
"ErrorsOut": {
"properties": {
"success": {
"default": false,
"title": "Success",
"type": "boolean"
},
"message": {
"default": "",
"title": "Message",
"type": "string"
},
"errors": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"type": "null"
}
],
"default": {},
"title": "Errors"
}
},
"title": "ErrorsOut",
"type": "object"
},
"PreCheckIn": {
"properties": {
"nzbn": {
"description": "The business's 13 digit New Zealand Business Number.",
"examples": [
"9429041547977"
],
"maxLength": 13,
"title": "Nzbn",
"type": "string"
},
"monthly_turnover": {
"anyOf": [
{
"minimum": 0.0,
"type": "number"
},
{
"pattern": "^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$",
"type": "string"
}
],
"description": "Average monthly turnover in NZD.",
"examples": [
12500.0
],
"title": "Monthly Turnover"
},
"trading_months": {
"anyOf": [
{
"minimum": 0,
"type": "integer"
},
{
"type": "null"
}
],
"description": "How many months the business has been trading.",
"examples": [
18
],
"title": "Trading Months"
},
"invoices_owed": {
"default": false,
"description": "Whether the business has unpaid invoices owed to it by its customers.",
"examples": [
true
],
"title": "Invoices Owed",
"type": "boolean"
}
},
"required": [
"nzbn",
"monthly_turnover"
],
"title": "PreCheckIn",
"type": "object"
},
"PreCheckOut": {
"properties": {
"eligible": {
"description": "True when the business qualifies for at least one funding option.",
"examples": [
true
],
"title": "Eligible",
"type": "boolean"
},
"products": {
"description": "Codes of the funding options the business qualifies for. Empty when `eligible` is false.",
"examples": [
[
"UNSECURED",
"LINE_OF_CREDIT",
"INVOICE_FINANCING"
]
],
"items": {
"$ref": "#/components/schemas/PreCheckProduct"
},
"title": "Products",
"type": "array"
}
},
"required": [
"eligible",
"products"
],
"title": "PreCheckOut",
"type": "object"
},
"PreCheckProduct": {
"description": "A funding option offered across the Bizzy lender panel: `UNSECURED` (unsecured business loan),\n`LINE_OF_CREDIT` (line of credit) or `INVOICE_FINANCING` (invoice finance).",
"enum": [
"UNSECURED",
"LINE_OF_CREDIT",
"INVOICE_FINANCING"
],
"title": "PreCheckProduct",
"type": "string"
},
"PreCheckThrottledOut": {
"properties": {
"success": {
"default": false,
"title": "Success",
"type": "boolean"
},
"detail": {
"examples": [
"Request was throttled. Expected available in 6 seconds."
],
"title": "Detail",
"type": "string"
}
},
"required": [
"detail"
],
"title": "PreCheckThrottledOut",
"type": "object"
},
"PreCheckValidationError": {
"properties": {
"type": {
"examples": [
"greater_than_equal"
],
"title": "Type",
"type": "string"
},
"loc": {
"examples": [
[
"body",
"payload",
"monthly_turnover"
]
],
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"title": "Loc",
"type": "array"
},
"msg": {
"examples": [
"Input should be greater than or equal to 0"
],
"title": "Msg",
"type": "string"
}
},
"required": [
"type",
"loc",
"msg"
],
"title": "PreCheckValidationError",
"type": "object"
}
}
}
}