Appearance
App
Apps: list, get, create, update and manage app members.
Endpoints
| Endpoint | Arguments | Returns |
|---|---|---|
v3.app.config.update | appId: string, config: any, workspaceId?: string | boolean |
v3.app.create | app: AppInput | object |
v3.app.list | workspaceId?: string | object[] |
v3.app.member.add | appId: string, permissionItem: string, workspaceId?: string | boolean |
v3.app.member.remove | appId: string, member: string, workspaceId?: string | boolean |
v3.app.product.create | input: { name: string } | unknown |
v3.app.product.get | targetId: string | unknown |
v3.app.product.getInstalledVersion | productId: string | object |
v3.app.product.getManifest | targetId: string | unknown |
v3.app.product.install | productId: string, workspaceId: string | boolean |
v3.app.product.isProductInstalled | productId: string, workspaceId: string | boolean |
v3.app.remove | appId: string, workspaceId?: string | unknown |
v3.app.update | appId: string, update: Partial<AppDoc>, workspaceId?: string | unknown |
v3.app.config.update
Description
Edit app configuration
Parameters
Argument 1 (ObjectId, required): appId
Argument 2 (object, required):
| Field | Type | Required | Description |
|---|---|---|---|
fields | Record<string, object> | no |
Argument 3 (WorkspaceId, optional): Workspace Id of the app. Required for workspace apps, omit for personal apps
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.config.update', [
'507f1f77bcf86cd799439011', // ObjectId (required)
{
fields: {
'507f1f77bcf86cd799439012': { /* ... */ }, // fieldId: value
},
},
'507f1f77bcf86cd799439011', // WorkspaceId
]);
console.log(result);Returns
boolean
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.create
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (object, optional):
| Field | Type | Required | Description |
|---|---|---|---|
cid | WorkspaceId | no | workspaceId (former networkId) |
name | string | yes | |
description | string | no | |
gitUrl | string | no | Optional git repository URL of the app source code |
url | string | no | |
image | fileId | no | DEPRECATED: use iconGenerator. Kept for older app-sdk compatibility. |
iconGenerator | object | no | |
config | object | no |
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.create', [
{
name: 'string',
},
]);
console.log(result);Returns
| Field | Type | Required | Description |
|---|---|---|---|
_id | ObjectId | yes | appId |
created | timestamp | yes | Time (milliseconds since 1970-01-01 UTC) |
updated | timestamp | yes | Time (milliseconds since 1970-01-01 UTC) |
cid | WorkspaceId | no | Workspace Id, leave empty for Personal apps |
uid | string | yes | |
name | string | yes | |
description | string | yes | |
gitUrl | string | no | Optional git repository URL of the app source code |
allowedUrls | string[] | no | |
members | object[] | yes | |
url | string | yes | |
image | fileId | no | fileId |
icon | fileId | no | fileId |
iconBadge | fileId | no | fileId |
iconGenerator | object | no | |
config | object | no | |
packageHash | ObjectId | no | |
isProductVersionAvailable | boolean | no |
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.list
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (WorkspaceId, optional): Workspace Id to list apps for. Omit to list only personal apps
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.list', [
'507f1f77bcf86cd799439011', // WorkspaceId
]);
console.log(result);Returns
Array of objects:
| Field | Type | Required | Description |
|---|---|---|---|
_id | ObjectId | yes | appId |
created | timestamp | yes | Time (milliseconds since 1970-01-01 UTC) |
updated | timestamp | yes | Time (milliseconds since 1970-01-01 UTC) |
cid | WorkspaceId | no | Workspace Id, leave empty for Personal apps |
uid | string | yes | |
name | string | yes | |
description | string | yes | |
gitUrl | string | no | Optional git repository URL of the app source code |
allowedUrls | string[] | no | |
members | object[] | yes | |
url | string | yes | |
image | fileId | no | fileId |
icon | fileId | no | fileId |
iconBadge | fileId | no | fileId |
iconGenerator | object | no | |
config | object | no | |
packageHash | ObjectId | no | |
isProductVersionAvailable | boolean | no |
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.member.add
Description
Add member
Parameters
Argument 1 (ObjectId, required): appId
Argument 2 (string, required): network_<networkId>, team_<teamId>, user_<userId>, group_<groupId>
Argument 3 (WorkspaceId, optional): Workspace Id of the app. Required for workspace apps, omit for personal apps
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.member.add', [
'507f1f77bcf86cd799439011', // ObjectId (required)
'string', // `network_<networkId>`, `team_<teamId>`, `user_<userId>`, `group_<groupId>` (required)
'507f1f77bcf86cd799439011', // WorkspaceId
]);
console.log(result);Returns
boolean
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.member.remove
Description
Remove member
Parameters
Argument 1 (ObjectId, required): appId
Argument 2 (string, required): network_<networkId>, team_<teamId>, user_<userId>, group_<groupId>
Argument 3 (WorkspaceId, optional): Workspace Id of the app. Required for workspace apps, omit for personal apps
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.member.remove', [
'507f1f77bcf86cd799439011', // ObjectId (required)
'string', // `network_<networkId>`, `team_<teamId>`, `user_<userId>`, `group_<groupId>` (required)
'507f1f77bcf86cd799439011', // WorkspaceId
]);
console.log(result);Returns
boolean
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.product.create
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (object, optional):
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Name of the version |
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.product.create', [
{
name: 'string', // Name of the version
},
]);
console.log(result);Returns
Undocumented
The return value is not described in the source yet.
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.product.get
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (ObjectId, required): Target Id in Hailer market
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.product.get', [
'507f1f77bcf86cd799439011', // ObjectId (required)
]);
console.log(result);Returns
Undocumented
The return value is not described in the source yet.
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.product.getInstalledVersion
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (ObjectId, required): Product Id in Hailer market
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.product.getInstalledVersion', [
'507f1f77bcf86cd799439011', // ObjectId (required)
]);
console.log(result);Returns
| Field | Type | Required | Description |
|---|---|---|---|
version | string | no | |
description | string | no | semver format (e.g., 1.0.0) |
packageHash | ObjectId | no | Description about the version |
created | timestamp | no | Time (milliseconds since 1970-01-01 UTC) |
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.product.getManifest
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (ObjectId, required): Target Id in Hailer market
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.product.getManifest', [
'507f1f77bcf86cd799439011', // ObjectId (required)
]);
console.log(result);Returns
Undocumented
The return value is not described in the source yet.
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.product.install
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (ObjectId, required): Product Id in Hailer market
Argument 2 (WorkspaceId, required): Workspace Id where it will be installed
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.product.install', [
'507f1f77bcf86cd799439011', // ObjectId (required)
'507f1f77bcf86cd799439011', // WorkspaceId (required)
]);
console.log(result);Returns
boolean
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.product.isProductInstalled
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (ObjectId, required): Product Id in Hailer market
Argument 2 (WorkspaceId, required): Workspace Id
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.product.isProductInstalled', [
'507f1f77bcf86cd799439011', // ObjectId (required)
'507f1f77bcf86cd799439011', // WorkspaceId (required)
]);
console.log(result);Returns
boolean
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.remove
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (ObjectId, required): appId
Argument 2 (WorkspaceId, optional): Workspace Id of the app. Required for workspace apps, omit for personal apps
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.remove', [
'507f1f77bcf86cd799439011', // ObjectId (required)
'507f1f77bcf86cd799439011', // WorkspaceId
]);
console.log(result);Returns
Undocumented
The return value is not described in the source yet.
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.
v3.app.update
Description
Undocumented
This endpoint has no description in the source yet.
Parameters
Argument 1 (ObjectId, required): appId
Argument 2 (object, required):
| Field | Type | Required | Description |
|---|---|---|---|
cid | WorkspaceId | no | workspaceId (former networkId) |
name | string | yes | |
description | string | no | |
gitUrl | string | no | Optional git repository URL of the app source code |
url | string | no | |
image | fileId | no | DEPRECATED: use iconGenerator. Kept for older app-sdk compatibility. |
iconGenerator | object | no | |
config | object | no |
Argument 3 (WorkspaceId, optional): Workspace Id of the app. Required for workspace apps, omit for personal apps
Example
javascript
const { Client } = require('@hailer/cli');
const client = await Client.create({
host: 'https://api.hailer.com',
username: 'you@example.com',
password: '••••••',
});
const result = await client.request('v3.app.update', [
'507f1f77bcf86cd799439011', // ObjectId (required)
{
name: 'string',
},
'507f1f77bcf86cd799439011', // WorkspaceId
]);
console.log(result);Returns
Undocumented
The return value is not described in the source yet.
Auth: requires an authenticated session.
Errors: on failure returns the standard Hailer error object { code, msg, details?, debug? }.