Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update gatsby to v5 #53

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions content-new/docs/api.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
title: "API"
order: 1
metaTitle: "API"
---
330 changes: 330 additions & 0 deletions content-new/docs/api/getting-started.mdx

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions content-new/docs/api/overview.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: "Overview"
order: 1
---

## Overview

For GET requests, you can use one or more query parameters. In the response we will return a HTTP status code. Some endpoints return JSON bodies that include HAL (Hypertext Application Language) links.
38 changes: 38 additions & 0 deletions content-new/docs/api/parameters.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"authorization": {
"name": "Authorization",
"type": "string",
"location": "header",
"required": true,
"methods": ["get", "post", "patch", "delete", "request"],
"body": "<p>Your API token retrieved from the portal.</p>",
"example": "curl -v -X GET https://institution-api-sim.clearbank.co.uk/v3/Accounts \\ \n -H \"Authorization: Bearer <<your api token>> \""
},
"digitalSignature": {
"name": "DigitalSignature",
"type": "string",
"location": "header",
"required": true,
"methods": ["post", "patch", "delete", "request"],
"body": "<p>This is a hash of the request body signed with your private key.</p>",
"example": null
},
"xRequestId": {
"name": "X-Request-Id",
"type": "string",
"location": "header",
"required": true,
"methods": ["post", "patch", "delete", "request"],
"body": "<p>This is what we use for idempotency and enables a duplication check. You generate this identifier which must be unique for any subsequent requests sent for at least 24 hours after the initial request was sent.</p><p> If an <code>X-Request-Id</code> Header is not supplied, or is invalid, a <code>400</code>:Bad Request HTTP status code response will be returned.</p><p>If ClearBank&reg; detects a duplicate, a <code>409</code>: Conflict HTTP status code response will be returned.<p>",
"example": null
},
"xCorrelationId": {
"name": "X-Correlation-Id",
"type": "string",
"location": "header",
"required": false,
"methods": ["response"],
"body": "<p>This is a unique identifier generated by ClearBank&reg; for the request. ClearBank&reg; would require this identifier for troubleshooting purposes. Therefore, it is recommended you store this response header.</p>",
"example": null
}
}
9 changes: 9 additions & 0 deletions content-new/docs/api/parameters.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
export interface Parameter {
name: string
type: string
location: string
required: boolean
methods: string[]
body: string
example?: string
}
24 changes: 24 additions & 0 deletions content-new/docs/api/support-lify-cycle.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
title: "Support life cycle"
order: 4
---

import Callout from "src/components/callout";

## Support life cycle

All endpoints and webhooks released by ClearBank will be supported for a minimum of 12 months before these are reviewed for withdrawal.

Following the initial 12-month period, all endpoints and webhooks will be reviewed every 6 months. This review will allow us to decide whether an endpoint or webhook should be withdrawn.
If we decide to withdraw an endpoint or webhook, you will be issued a written notification 6 months prior to the date from which that version will no longer be supported.

This means that all endpoints and webhooks will ideally be supported for a minimum of 18 months (this includes initial support for 12 months along with a 6-month advance notice period prior to withdrawal).

The only exception to this approach would be for us to withdraw an endpoint or webhook sooner due to regulatory or scheme obligations, or in case of API incompatibility.

As a matter of practice, you are urged to ensure that you upgrade to the latest version of an endpoint or webhook as soon as one is released.

<Callout colour="blue">
Any changes to our API versioning approach will be communicated to you at
least 6 months prior to implementation.
</Callout>
17 changes: 17 additions & 0 deletions content-new/docs/api/versioning.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
title: "Versioning"
order: 3
---

## Versioning

Providing developers with a seamless integration experience is at the core of our API versioning approach. We work in an agile environment and iteratively release the latest versions of individual endpoints and webhooks.

We follow the Semantic Versioning specification (https://semver.org/):

- Internally, we update minor and patch versions whenever we add optional functionality and backwards compatible changes.
- Whenever we introduce a breaking change, we will provision a new major version of the API.

All API endpoints are versioned through the URI path; for example, /v2/Accounts. Endpoint details can be found on the Developer Portal.

A backwards compatible change does not affect existing integrations for tolerant readers, for example the addition of new optional fields for an API request, response or a webhook payload. A breaking change could affect existing integrations, for example the addition of a new mandatory field or removal of an existing field.
5 changes: 5 additions & 0 deletions content-new/docs/embedded-banking.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
title: "Embedded Banking"
order: 5
metaTitle: "Embedded Banking"
---
59 changes: 59 additions & 0 deletions content-new/docs/embedded-banking/fscs-protected-deposits.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
title: "FSCS protected deposites"
order: 1
---

import EndpointBlock from "src/components/endpoint-block";
import * as CONSTANTS from "./retail-customers.constants"

## FSCS protected deposites

FSCS-protected deposits are a part of our embedded banking proposition. An FSCS-protected deposit is a physical account held with ClearBank and is only available to our embedded banking customers for the purpose of sending and/or receiving payments. The balance of an FSCS-protected deposit is held by ClearBank and can be viewed via the ClearBank Portal and the API. Additionally, FSCS-protected deposits are reconciled for you by ClearBank.

<EndpointBlock
type="post"
title="Create a retail customer"
description={CONSTANTS.postCustomersRetailDescription}
endpoints={[
{
path: "/v1/customers/retail",
version: "1.0.Retail"
}
]}
/>

<EndpointBlock
type="post"
title="Create an account"
endpoints={[
{
path: "/v4/Accounts",
version: "4.0.Sterling",
webhooks: [
'account-created-webhook-v1'
]
}
]}
/>

<EndpointBlock
type="patch"
title="Update an existing retail customer’s personal information"
endpoints={[
{
path: "/v1/customers/retail/{customerId}",
version: "1.0.Retail"
}
]}
/>

<EndpointBlock
type="put"
title="Update an existing retail customer’s address"
endpoints={[
{
path: "/v1/customers/retail/{customerId}/currentaddress",
version: "1.0.Retail"
}
]}
/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import React from "react";

export const postCustomersRetailDescription = (
<>
<p>
Once you have created a retail customer, create a new FSCS protected current account using the retail customer’s unique Id.
</p>
</>
);
5 changes: 5 additions & 0 deletions content-new/docs/gbp-accounts.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
title: "GBP Accounts"
order: 2
metaTitle: "GBP Accounts"
---
31 changes: 31 additions & 0 deletions content-new/docs/gbp-accounts/account-types.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
title: "Account types"
order: 1
---

import Callout from "src/components/callout";

## Overview

There are several types of accounts that can be created. Which you should use will depend on your agreement with ClearBank, and the purpose of the account.

When you join ClearBank you are given these five accounts by default:

![Image showing your initial set of accounts](/assets/images/Accounts-Day1.svg "Initial set of accounts")

Your **institution account** is not an account of its own; it is a superset of all your other accounts. Your **operating account** holds your own operational funds and your **general segregation account** can be used for multiple customers' funds that need to be safeguarded. Note that a segregation account should not be used to hold any of your own funds.

You can create additional operational and safeguarding accounts as needed. You can also create virtual accounts within a general segregation account or a general client account.

![Image showing correct usage of usageType/kind](/assets/images/Accounts-Usage.svg "Correct usage of usageType/kind")

It is important to **select the correct usage for the account when you create it, as this cannot be amended later**. The account usage determines, for example, whether the account can be used for safeguarding funds.

When you create a real account:
- For sterling accounts - use the **UsageType** field to select YourFunds, SegregatedDesignated, or SegregatedGeneral, as shown above. If you need to create a client account, first create a safeguarding account through the API, then contact client services through FreshDesk to have the type transferred to a client account.

- For multi-currency accounts - use the **Kind** field to select YourFunds, DesignatedSegregated, GeneralSegregated, DesignatedClient, or GeneralClient.

The UsageType or Kind value determines the autogenerated prefix assigned to the account, for example, 'Gen Seg Acc Retl'. The prefixes for each account are shown in the figure above.

The endpoints described below are used to manage sterling accounts. For multi-currency accounts, see [Multi-currency Accounts](./multicurrency-accounts).
4 changes: 4 additions & 0 deletions content-new/docs/gbp-accounts/bacs-payment-data.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
title: "BACS Payment data"
order: 4
---
Loading