Skip to content

setCurrentCountry

setCurrentCountry ​

Definition ​

Set the current session's country

Signature ​

ts
export async function setCurrentCountry(
  newCountryId: string,
  contextInstance: ShopwareApiInstance = defaultInstance,
): Promise<ContextTokenResponse>

Parameters ​

NameTypeDescription
newCountryId
string
id of the country
contextInstance
ShopwareApiInstance
instance of the api client (by default it's an Axios instance)

Return type ​

ts
Promise<ContextTokenResponse>

Usage example ​

WARNING

Example is generated automatically. Sometimes it's required to be adjusted to your needs.

Open in StackBlitz