V1 endpoints

These endpoints require a Portal API Key (aka "Custodian API Key") as a bearer token.

Before going live with real users, always ensure that you create clients using a Portal API Key from your Portal's Production environment. Read more here on going live with real users.

Create a new client

POST https://api.portalhq.io/api/v1/custodians/clients

Registers a new client and returns a client session token.

Headers

NameTypeDescription

Authorization*

String

Bearer <Portal API Key>

Content-Type*

String

application/json

Request Body

NameTypeDescription

isAccountAbstracted

Boolean

The client will use ERC-4337 Account Abstraction.

{
  "id": "string",
  "clientApiKey": "string",
  "clientSessionToken": "string",
  "isAccountAbstracted": boolean
}

Fetches a single client

GET https://api.portalhq.io/api/v1/custodians/clients/{clientId}

Fetches the specified client for the authorized custodian.

Path Parameters

NameTypeDescription

clientId*

String

The ID of a client.

Headers

NameTypeDescription

Authorization*

String

Bearer <Portal API Key>

Content-Type*

String

application/json

{
  "id": "string",
  "address": "string",
  "clientApiKey": "string",
  "isAccountAbstracted": boolean
}

Fetches a list of clients

GET https://api.portalhq.io/api/v1/custodians/clients

Fetches all clients for the authorized custodian.

Headers

NameTypeDescription

Authorization*

String

Bearer <Portal API Key>

Content-Type*

String

application/json

[
  {
    "id": "string",
    "address": "string",
    "backupStatus": "string",
    "clientApiKey": "string",
    "signingStatus": "string"
  }
]

Refresh Client Session Token (CST)

POST https://api.portalhq.io/api/v1/custodians/clients/{clientId}/session

Refreshes a client's Client Session Token.

Path Parameters

NameTypeDescription

clientId

String

The ID of a client.

Headers

NameTypeDescription

Authorization*

String

Bearer <Portal API Key>

Content-Type*

String

application/json

{
  "id": "string",
  "clientSessionToken": "string",
  "isAccountAbstracted": boolean
}

Generate Client Web One-Time Password (OTP)

GET https://api.portalhq.io/api/v1/custodians/clients/{clientId}/web-otp

Generate a one-time password for a client.

Path Parameters

NameTypeDescription

clientId*

String

The ID of a client.

Headers

NameTypeDescription

Authorization*

String

Bearer <Portal API Key>

Content-Type*

String

application/json

{
  "id": "string"
  "otp": "string"
}

Last updated