Skip to main content
Version: 23.2.x

Class: Offering

api/entities/Offering.Offering

Represents an Asset Offering in the Polymesh blockchain

Hierarchy

Properties

asset

asset: FungibleAsset

Asset being offered

Defined in

api/entities/Offering/index.ts:65


id

id: BigNumber

identifier number of the Offering

Defined in

api/entities/Offering/index.ts:60


uuid

uuid: string

Inherited from

Entity.uuid

Defined in

api/entities/Entity.ts:46

Methods

close

close(opts?): Promise<GenericPolymeshTransaction<void, void>>

Close the Offering

Parameters

NameType
opts?ProcedureOpts

Returns

Promise<GenericPolymeshTransaction<void, void>>

Note

this method is of type NoArgsProcedureMethod, which means you can call close.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it

Defined in

api/entities/Offering/index.ts:160


details

details(): Promise<OfferingDetails>

Retrieve the Offering's details

Returns

Promise<OfferingDetails>

Note

can be subscribed to

Defined in

api/entities/Offering/index.ts:111

details(callback): Promise<UnsubCallback>

Parameters

NameType
callbackSubCallback<OfferingDetails>

Returns

Promise<UnsubCallback>

Defined in

api/entities/Offering/index.ts:112


exists

exists(): Promise<boolean>

Determine whether this Offering exists on chain

Returns

Promise<boolean>

Overrides

Entity.exists

Defined in

api/entities/Offering/index.ts:271


freeze

freeze(opts?): Promise<GenericPolymeshTransaction<Offering, Offering>>

Freeze the Offering

Parameters

NameType
opts?ProcedureOpts

Returns

Promise<GenericPolymeshTransaction<Offering, Offering>>

Note

this method is of type NoArgsProcedureMethod, which means you can call freeze.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it

Defined in

api/entities/Offering/index.ts:170


getInvestments

getInvestments(opts?): Promise<ResultSet<Investment>>

Retrieve all investments made on this Offering

Parameters

NameTypeDescription
optsObject-
opts.size?BigNumberpage size
opts.start?BigNumberpage offset

Returns

Promise<ResultSet<Investment>>

Note

supports pagination

Note

uses the middleware V2

Defined in

api/entities/Offering/index.ts:222


invest

invest(args, opts?): Promise<GenericPolymeshTransaction<void, void>>

Invest in the Offering

Parameters

NameType
argsInvestInOfferingParams
opts?ProcedureOpts

Returns

Promise<GenericPolymeshTransaction<void, void>>

Note

required roles:

  • Purchase Portfolio Custodian
  • Funding Portfolio Custodian

Note

this method is of type ProcedureMethod, which means you can call invest.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it

Defined in

api/entities/Offering/index.ts:209


isEqual

isEqual(entity): boolean

Determine whether this Entity is the same as another one

Parameters

NameType
entityEntity<unknown, unknown>

Returns

boolean

Inherited from

Entity.isEqual

Defined in

api/entities/Entity.ts:61


modifyTimes

modifyTimes(args, opts?): Promise<GenericPolymeshTransaction<void, void>>

Modify the start/end time of the Offering

Parameters

NameType
argsModifyOfferingTimesParams
opts?ProcedureOpts

Returns

Promise<GenericPolymeshTransaction<void, void>>

Throws

if:

  • Trying to modify the start time on an Offering that already started
  • Trying to modify anything on an Offering that already ended
  • Trying to change start or end time to a past date

Note

this method is of type ProcedureMethod, which means you can call modifyTimes.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it

Defined in

api/entities/Offering/index.ts:195


toHuman

toHuman(): HumanReadable

Return the Offering's ID and Asset ticker

Returns

HumanReadable

Overrides

Entity.toHuman

Defined in

api/entities/Offering/index.ts:289


unfreeze

unfreeze(opts?): Promise<GenericPolymeshTransaction<Offering, Offering>>

Unfreeze the Offering

Parameters

NameType
opts?ProcedureOpts

Returns

Promise<GenericPolymeshTransaction<Offering, Offering>>

Note

this method is of type NoArgsProcedureMethod, which means you can call unfreeze.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it

Defined in

api/entities/Offering/index.ts:180


generateUuid

Static generateUuid<Identifiers>(identifiers): string

Generate the Entity's UUID from its identifying properties

Type parameters

Name
Identifiers

Parameters

NameType
identifiersIdentifiers

Returns

string

Inherited from

Entity.generateUuid

Defined in

api/entities/Entity.ts:14


unserialize

Static unserialize<Identifiers>(serialized): Identifiers

Unserialize a UUID into its Unique Identifiers

Type parameters

Name
Identifiers

Parameters

NameTypeDescription
serializedstringUUID to unserialize

Returns

Identifiers

Inherited from

Entity.unserialize

Defined in

api/entities/Entity.ts:23