queryNetworkByName
queryNetworkByName(
connection,name,requestTimeout?):Promise<NetworkRecord>
Defined in: queryNetworkByName.ts:38
Looks up a Network (Experience Cloud site) by name, bounded by requestTimeout with the request
cancelled if it stalls. A drop-in for connection.singleRecordQuery(): it throws the same error
names (SingleRecordQuery_NoRecords, SingleRecordQuery_MultipleRecords), which
@salesforce/core doesn’t export as values.
Parameters
Section titled “Parameters”connection
Section titled “connection”Connection
The org connection.
string
The Network.Name to find.
requestTimeout?
Section titled “requestTimeout?”Duration = DEFAULT_PUBLISH_REQUEST_TIMEOUT
Bounds the query. Defaults to DEFAULT_PUBLISH_REQUEST_TIMEOUT.
Returns
Section titled “Returns”Promise<NetworkRecord>
The matching record’s Id and Name.
Throws
Section titled “Throws”SingleRecordQuery_NoRecords / SingleRecordQuery_MultipleRecords unless exactly one matches.