Skip to content

AddressSecp256k1

Defined in: packages/iso-filecoin/src/address.js:601

Secp256k1 address f1..

See

https://spec.filecoin.io/appendix/address/#section-appendix.address.protocol-1-libsecpk1-elliptic-curve-public-keys

Implements

Extends

Constructors

new AddressSecp256k1()

new AddressSecp256k1(payload: Uint8Array<ArrayBufferLike>, network: Network): AddressSecp256k1

Defined in: packages/iso-filecoin/src/address.js:607

Parameters

ParameterTypeDescription
payloadUint8Array<ArrayBufferLike>
networkNetwork

Returns

AddressSecp256k1

Overrides

Address.constructor

Methods

checksum()

checksum(): Uint8Array<ArrayBufferLike>

Defined in: packages/iso-filecoin/src/address.js:337

Returns

Uint8Array<ArrayBufferLike>

Inherited from

Address.checksum


to0x()

to0x(options: AddressRpcSafetyOptions): Promise<string>

Defined in: packages/iso-filecoin/src/address.js:399

Converts any address to a 0x address, either id masked address or eth address depending on the address type. Delegated addresses convert to eth address and f1, f2, f3 convert to id masked address and f0 depends on the underline address type

Parameters

ParameterTypeDescription
optionsAddressRpcSafetyOptions

Returns

Promise<string>

Inherited from

Address.to0x


toBytes()

toBytes(): Uint8Array<ArrayBuffer>

Defined in: packages/iso-filecoin/src/address.js:329

Returns

Uint8Array<ArrayBuffer>

Inherited from

Address.toBytes


toContractDestination()

toContractDestination(): `0x${string}`

Defined in: packages/iso-filecoin/src/address.js:333

Returns

`0x${string}`

Inherited from

Address.toContractDestination


toIdAddress()

toIdAddress(options: AddressRpcSafetyOptions): Promise<AddressId>

Defined in: packages/iso-filecoin/src/address.js:348

Convert to ID address

Parameters

ParameterTypeDescription
optionsAddressRpcSafetyOptions

Returns

Promise<AddressId>

Inherited from

Address.toIdAddress


toString()

toString(): string

Defined in: packages/iso-filecoin/src/address.js:323

Returns

string

Inherited from

Address.toString


fromBytes()

static fromBytes(bytes: Uint8Array<ArrayBufferLike>, network: Network): AddressSecp256k1

Defined in: packages/iso-filecoin/src/address.js:651

Create address from bytes

Parameters

ParameterTypeDescription
bytesUint8Array<ArrayBufferLike>
networkNetwork

Returns

AddressSecp256k1


fromPublicKey()

static fromPublicKey(publicKey: Uint8Array<ArrayBufferLike>, network: Network): AddressSecp256k1

Defined in: packages/iso-filecoin/src/address.js:662

Parameters

ParameterTypeDescription
publicKeyUint8Array<ArrayBufferLike>
networkNetwork

Returns

AddressSecp256k1


fromString()

static fromString(address: string): AddressSecp256k1

Defined in: packages/iso-filecoin/src/address.js:621

Create address from string

Parameters

ParameterTypeDescription
addressstring

Returns

AddressSecp256k1

Properties

[symbol]

[symbol]: boolean = true;

Defined in: packages/iso-filecoin/src/address.js:308

Inherited from

Address.[symbol]


network

network: Network;

Defined in: packages/iso-filecoin/src/address.js:317

Inherited from

Address.network


networkPrefix

networkPrefix: "f" | "t";

Defined in: packages/iso-filecoin/src/address.js:318

Inherited from

Address.networkPrefix


payload

payload: Uint8Array<ArrayBufferLike>;

Defined in: packages/iso-filecoin/src/address.js:316

Inherited from

Address.payload


protocol

protocol: 1;

Defined in: packages/iso-filecoin/src/address.js:609

Inherited from

Address.protocol