Skip to main content

@justaname.id/sdk

Classes

Interfaces

Type Aliases

ChainId

Ƭ ChainId: 1 | 11155111

Represents the blockchain network identifier, restricting to specific networks. This type is used to specify and restrict operations to the following chain IDs:

  • 1: Ethereum Mainnet
  • 11155111: An example of a testnet or custom network ID

Defined in

lib/types/common/index.ts:9


CoinAndDetails

Ƭ CoinAndDetails: Coin & CoinType

Defined in

lib/utils/sanitizeRecords/index.ts:5


CoinTypeKeys

Ƭ CoinTypeKeys: keyof typeof coinTypeMap

Defined in

lib/utils/cointypes/index.ts:23


GeneralsIdentifier

Ƭ GeneralsIdentifier: "display" | "description" | "url" | "location" | "avatar" | "banner"

Defined in

lib/constants/general-fields/index.ts:3


GeneralsName

Ƭ GeneralsName: "Nickname" | "Description" | "Website" | "Location" | "Avatar" | "Banner"

Defined in

lib/constants/general-fields/index.ts:1


IROUTES

Ƭ IROUTES: { [key in RoutesType]: IRoute }

Defined in

lib/api/routes/index.ts:67


RoutesType

Ƭ RoutesType: keyof typeof Routes

Defined in

lib/api/routes/index.ts:65


SocialDetails

Ƭ SocialDetails: Text & { name: SupportedSocialsNames }

Defined in

lib/utils/sanitizeRecords/index.ts:7


SocialsIdentifier

Ƭ SocialsIdentifier: "com.twitter" | "com.facebook" | "com.instagram" | "com.reddit" | "com.x" | "com.github" | "email" | "org.telegram"

Defined in

lib/constants/supported-socials/index.ts:11


SocialsName

Ƭ SocialsName: "Twitter" | "Facebook" | "Instagram" | "Reddit" | "X" | "Github" | "Email" | "Telegram"

Defined in

lib/constants/supported-socials/index.ts:1


SupportedGeneralsNames

Ƭ SupportedGeneralsNames: typeof GENERAL_FIELDS[number][``"name"``]

Defined in

lib/constants/general-fields/index.ts:39


SupportedSocialsNames

Ƭ SupportedSocialsNames: typeof SUPPORTED_SOCIALS[number][``"name"``]

Defined in

lib/constants/supported-socials/index.ts:107

Variables

GENERAL_FIELDS

Const GENERAL_FIELDS: readonly Generals[]

Defined in

lib/constants/general-fields/index.ts:12


Routes

Const Routes: Object

Type declaration

NameType
ACCEPT_SUBNAME_ROUTEstring
ADD_SUBNAME_ROUTEstring
CHECK_SUBNAME_AVAILABILITY_ROUTEstring
GET_ALL_COMMUNITIES_WITH_COUNT_ROUTEstring
GET_ALL_SUBNAMES_BY_ADDRESS_ROUTEstring
GET_ALL_SUBNAMES_BY_DOMAIN_ROUTEstring
GET_ALL_SUBNAMES_BY_INVITATION_ROUTEstring
GET_SUBNAME_BY_DOMAIN_NAME_CHAIN_ID_ROUTEstring
GET_SUBNAME_BY_SUBNAME_ROUTEstring
HEALTH_CHECK_ROUTEstring
RECORDS_BY_FULLNAME_ROUTEstring
REJECT_SUBNAME_ROUTEstring
RESERVE_SUBNAME_ROUTEstring
REVOKE_SUBNAME_ROUTEstring
SEARCH_SUBNAMES_ROUTEstring
SIWE_REQUEST_CHALLENGE_ROUTEstring
SIWE_VERIFY_MESSAGE_ROUTEstring
UPDATE_SUBNAME_ROUTEstring

Defined in

lib/api/routes/index.ts:44


SUPPORTED_SOCIALS

Const SUPPORTED_SOCIALS: readonly Socials[]

Defined in

lib/constants/supported-socials/index.ts:27


coinTypeMap

Const coinTypeMap: CoinTypeMap

Defined in

lib/utils/cointypes/index.ts:12

Functions

createAddresses

createAddresses(coins): CoinAndDetails[]

Parameters

NameType
coinsCoin[]

Returns

CoinAndDetails[]

Defined in

lib/utils/sanitizeRecords/index.ts:41


createGenerals

createGenerals(texts): Text[]

Parameters

NameType
textsText[]

Returns

Text[]

Defined in

lib/utils/sanitizeRecords/index.ts:68


createSocialsAndOthers

createSocialsAndOthers(texts): [SocialDetails[], Text[]]

Parameters

NameType
textsText[]

Returns

[SocialDetails[], Text[]]

Defined in

lib/utils/sanitizeRecords/index.ts:50


getCoinTypeDetails

getCoinTypeDetails(cointype): CoinType

Parameters

NameType
cointypestring | number

Returns

CoinType

Defined in

lib/utils/cointypes/index.ts:26


sanitizeRecords

sanitizeRecords(records): SanitizedRecords

Parameters

NameType
recordsundefined | SubnameRecordsResponse

Returns

SanitizedRecords

Defined in

lib/utils/sanitizeRecords/index.ts:78