Skip to content

App

Defines an App on Bkper.

Apps can be installed on Books by users.

Extends

  • Resource<bkper.App>

Constructors

Constructor

new App(payload?, config?): App;

Parameters

ParameterType
payload?App
config?Config

Returns

App

Overrides

Resource<bkper.App>.constructor

Properties

payload

payload: App;

The underlying payload data for this resource

Inherited from

Resource.payload

Methods

create()

create(): Promise<App>;

Performs the app creation, applying pending changes.

The App id MUST be unique. If another app is already existing, an error will be thrown.

Returns

Promise<App>

This App after creation


getDescription()

getDescription(): string | undefined;

Gets the description of this App.

Returns

string | undefined

The description of this App


getDevelopers()

getDevelopers(): string | undefined;

Gets the developers (usernames and domain patterns).

Returns

string | undefined

The developers string


getEvents()

getEvents(): EventType[] | undefined;

Gets the events bound to this App.

Returns

EventType[] | undefined

The events bound to this App


getFilePatterns()

getFilePatterns(): string[] | undefined;

Gets the file patterns the App handles.

Returns

string[] | undefined

The file patterns the App handles - E.g *.pdf *.csv


getId()

getId(): string | undefined;

Gets the App universal identifier.

Returns

string | undefined

The App universal identifier


getLogoUrl()

getLogoUrl(): string | undefined;

Gets the logo url of this App.

Returns

string | undefined

The logo url of this App


getLogoUrlDark()

getLogoUrlDark(): string | undefined;

Gets the logo url of this App in dark mode.

Returns

string | undefined

The logo url of this App in dark mode


getMenuPopupHeight()

getMenuPopupHeight(): string | undefined;

Gets the menu popup height of this App.

Returns

string | undefined

The menu popup height of this App


getMenuPopupWidth()

getMenuPopupWidth(): string | undefined;

Gets the menu popup width of this App.

Returns

string | undefined

The menu popup width of this App


getMenuText()

getMenuText(): string | undefined;

Gets the menu text of this App.

Returns

string | undefined

The menu text of this App


getMenuUrl()

getMenuUrl(): string | undefined;

Gets the menu url of this App.

Returns

string | undefined

The menu url of this App


getMenuUrlDev()

getMenuUrlDev(): string | undefined;

Gets the menu development url of this App.

Returns

string | undefined

The menu development url of this App


getName()

getName(): string | undefined;

Gets the name of this App.

Returns

string | undefined

The name of this App


getOwnerLogoUrl()

getOwnerLogoUrl(): string | undefined;

Gets the logo url of the owner of this App.

Returns

string | undefined

The logo url of the owner of this App


getOwnerName()

getOwnerName(): string | undefined;

Gets the name of the owner of this App.

Returns

string | undefined

The name of the owner of this App


getOwnerWebsiteUrl()

getOwnerWebsiteUrl(): string | undefined;

Gets the website url of the owner of this App.

Returns

string | undefined

The website url of the owner of this App


getReadme()

getReadme(): string | undefined;

Gets the readme.md file as text.

Returns

string | undefined

The readme text


getRepositoryUrl()

getRepositoryUrl(): string | undefined;

Gets the repository url of this App.

Returns

string | undefined

The repository url of this App


getUsers()

getUsers(): string | undefined;

Gets the whitelisted users (usernames and domain patterns).

Returns

string | undefined

The users string


getWebsiteUrl()

getWebsiteUrl(): string | undefined;

Gets the website url of this App.

Returns

string | undefined

The website url of this App


hasEvents()

hasEvents(): boolean;

Checks if this App has events bound to it.

Returns

boolean

True if this App has events bound to it


isInstallable()

isInstallable(): boolean;

Tells if this App is installable.

Returns

boolean

True if this App is installable


isPublished()

isPublished(): boolean;

Checks if this App is published.

Returns

boolean

True if this App is published


isRepositoryPrivate()

isRepositoryPrivate(): boolean | undefined;

Tells if the repository is private.

Returns

boolean | undefined

True if the repository is private


json()

json(): App;

Gets an immutable copy of the JSON payload for this resource.

Returns

App

An immutable copy of the json payload

Inherited from

Resource.json

setClientSecret()

setClientSecret(clientSecret?): App;

Sets the client secret.

Parameters

ParameterTypeDescription
clientSecret?stringThe client secret to set

Returns

App

This App for chaining


setDevelopers()

setDevelopers(developers?): App;

Sets the developers (usernames and domain patterns).

Parameters

ParameterTypeDescription
developers?stringThe developers (comma or space separated usernames and domain patterns like *@domain.com)

Returns

App

This App for chaining


setReadme()

setReadme(readme?): App;

Sets the readme.md file as text.

Parameters

ParameterTypeDescription
readme?stringThe readme text to set

Returns

App

This App, for chaining


setUsers()

setUsers(users?): App;

Sets the whitelisted users (usernames and domain patterns).

Parameters

ParameterTypeDescription
users?stringThe users to whitelist (comma or space separated usernames and domain patterns like *@domain.com)

Returns

App

This App for chaining


setWebhookUrlDev()

setWebhookUrlDev(webhookUrlDev): App;

Sets the webhook url for development.

Parameters

ParameterTypeDescription
webhookUrlDevstringThe webhook URL for development

Returns

App

This App, for chaining


update()

update(): Promise<App>;

Performs a full update of the App, applying pending changes.

Returns

Promise<App>

This App after the update