---
displayed_sidebar: jsClientSidebar
slug: /references/js-client/AdminStoresResource
---

import ParameterTypes from "@site/src/components/ParameterTypes"

# AdminStoresResource

This class is used to send requests to [Admin Store API Routes](https://docs.medusajs.com/api/admin#store). All its method
are available in the JS Client under the `medusa.admin.store` property.

All methods in this class require [user authentication](js_client.AdminAuthResource.mdx#createsession).

A store indicates the general configurations and details about the commerce store. By default, there's only one store in the Medusa backend.
Admins can manage the store and its details or configurations.

## Methods

### addCurrency

Add a currency code to the available currencies in a store. This doesn't create new currencies, as currencies are defined within the Medusa backend. 
To create a currency, you can [create a migration](https://docs.medusajs.com/development/entities/migrations/create) that inserts the currency into the database.

#### Example

```ts
import Medusa from "@medusajs/medusa-js"
const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
// must be previously logged in or use api token
medusa.admin.store.addCurrency("eur")
.then(({ store }) => {
  console.log(store.currencies);
})
```

#### Parameters

<ParameterTypes parameters={[
  {
    "name": "currency_code",
    "type": "`string`",
    "description": "The code of the currency to add to the store.",
    "optional": false,
    "defaultValue": "",
    "expandable": false,
    "children": []
  },
  {
    "name": "customHeaders",
    "type": "`Record<string, any>`",
    "description": "Custom headers to attach to the request.",
    "optional": false,
    "defaultValue": "{}",
    "expandable": false,
    "children": []
  }
]} expandUrl="https://docs.medusajs.com/js-client/overview#expanding-fields"/>

#### Returns

<ParameterTypes parameters={[
  {
    "name": "ResponsePromise",
    "type": "ResponsePromise&#60;AdminStoresRes&#62;",
    "optional": false,
    "defaultValue": "",
    "description": "Resolves to the store's details.",
    "expandable": false,
    "children": [
      {
        "name": "store",
        "type": "[Store](../../entities/classes/entities.Store.mdx)",
        "description": "Store details.",
        "optional": false,
        "defaultValue": "",
        "expandable": false,
        "children": [
          {
            "name": "created_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was created.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "currencies",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)[]",
            "description": "The details of the enabled currencies in the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)",
            "description": "The details of the store's default currency.",
            "optional": false,
            "defaultValue": "usd",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency_code",
            "type": "`string`",
            "description": "The three character currency code that is the default of the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_location_id",
            "type": "`string`",
            "description": "The location ID the store is associated with.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_sales_channel",
            "type": "[SalesChannel](../../entities/classes/entities.SalesChannel.mdx)",
            "description": "The details of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "created_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was created.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "deleted_at",
                "type": "`null` \\| `Date`",
                "description": "The date with timezone at which the resource was deleted.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "description",
                "type": "`null` \\| `string`",
                "description": "The description of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "id",
                "type": "`string`",
                "description": "The sales channel's ID",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "is_disabled",
                "type": "`boolean`",
                "description": "Specify if the sales channel is enabled or disabled.",
                "optional": false,
                "defaultValue": "false",
                "expandable": false,
                "children": []
              },
              {
                "name": "locations",
                "type": "[SalesChannelLocation](../../entities/classes/entities.SalesChannelLocation.mdx)[]",
                "description": "The details of the stock locations related to the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": true,
                "children": []
              },
              {
                "name": "metadata",
                "type": "`null` \\| `Record<string, unknown>`",
                "description": "An optional key-value map with additional details",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The name of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "updated_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was updated.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_sales_channel_id",
            "type": "`null` \\| `string`",
            "description": "The ID of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "id",
            "type": "`string`",
            "description": "The store's ID",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "invite_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Invite links from",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "metadata",
            "type": "`null` \\| `Record<string, unknown>`",
            "description": "An optional key-value map with additional details",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "name",
            "type": "`string`",
            "description": "The name of the Store - this may be displayed to the Customer.",
            "optional": false,
            "defaultValue": "Medusa Store",
            "expandable": false,
            "children": []
          },
          {
            "name": "payment_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Payment links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the payment's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "swap_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Swap links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the Swap's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "updated_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was updated.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          }
        ]
      }
    ]
  }
]} />

___

### deleteCurrency

Delete a currency code from the available currencies in a store. This doesn't completely delete the currency and it can be added again later to the store.

#### Example

```ts
import Medusa from "@medusajs/medusa-js"
const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
// must be previously logged in or use api token
medusa.admin.store.deleteCurrency("eur")
.then(({ store }) => {
  console.log(store.currencies);
})
```

#### Parameters

<ParameterTypes parameters={[
  {
    "name": "currency_code",
    "type": "`string`",
    "description": "The code of the currency to delete from the store.",
    "optional": false,
    "defaultValue": "",
    "expandable": false,
    "children": []
  },
  {
    "name": "customHeaders",
    "type": "`Record<string, any>`",
    "description": "Custom headers to attach to the request.",
    "optional": false,
    "defaultValue": "{}",
    "expandable": false,
    "children": []
  }
]} expandUrl="https://docs.medusajs.com/js-client/overview#expanding-fields"/>

#### Returns

<ParameterTypes parameters={[
  {
    "name": "ResponsePromise",
    "type": "ResponsePromise&#60;AdminStoresRes&#62;",
    "optional": false,
    "defaultValue": "",
    "description": "Resolves to the store's details.",
    "expandable": false,
    "children": [
      {
        "name": "store",
        "type": "[Store](../../entities/classes/entities.Store.mdx)",
        "description": "Store details.",
        "optional": false,
        "defaultValue": "",
        "expandable": false,
        "children": [
          {
            "name": "created_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was created.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "currencies",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)[]",
            "description": "The details of the enabled currencies in the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)",
            "description": "The details of the store's default currency.",
            "optional": false,
            "defaultValue": "usd",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency_code",
            "type": "`string`",
            "description": "The three character currency code that is the default of the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_location_id",
            "type": "`string`",
            "description": "The location ID the store is associated with.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_sales_channel",
            "type": "[SalesChannel](../../entities/classes/entities.SalesChannel.mdx)",
            "description": "The details of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "created_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was created.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "deleted_at",
                "type": "`null` \\| `Date`",
                "description": "The date with timezone at which the resource was deleted.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "description",
                "type": "`null` \\| `string`",
                "description": "The description of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "id",
                "type": "`string`",
                "description": "The sales channel's ID",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "is_disabled",
                "type": "`boolean`",
                "description": "Specify if the sales channel is enabled or disabled.",
                "optional": false,
                "defaultValue": "false",
                "expandable": false,
                "children": []
              },
              {
                "name": "locations",
                "type": "[SalesChannelLocation](../../entities/classes/entities.SalesChannelLocation.mdx)[]",
                "description": "The details of the stock locations related to the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": true,
                "children": []
              },
              {
                "name": "metadata",
                "type": "`null` \\| `Record<string, unknown>`",
                "description": "An optional key-value map with additional details",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The name of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "updated_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was updated.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_sales_channel_id",
            "type": "`null` \\| `string`",
            "description": "The ID of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "id",
            "type": "`string`",
            "description": "The store's ID",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "invite_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Invite links from",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "metadata",
            "type": "`null` \\| `Record<string, unknown>`",
            "description": "An optional key-value map with additional details",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "name",
            "type": "`string`",
            "description": "The name of the Store - this may be displayed to the Customer.",
            "optional": false,
            "defaultValue": "Medusa Store",
            "expandable": false,
            "children": []
          },
          {
            "name": "payment_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Payment links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the payment's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "swap_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Swap links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the Swap's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "updated_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was updated.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          }
        ]
      }
    ]
  }
]} />

___

### listPaymentProviders

Retrieve a list of available payment providers in a store.

#### Example

```ts
import Medusa from "@medusajs/medusa-js"
const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
// must be previously logged in or use api token
medusa.admin.store.listPaymentProviders()
.then(({ payment_providers }) => {
  console.log(payment_providers.length);
})
```

#### Parameters

<ParameterTypes parameters={[
  {
    "name": "customHeaders",
    "type": "`Record<string, any>`",
    "description": "Custom headers to attach to the request.",
    "optional": false,
    "defaultValue": "{}",
    "expandable": false,
    "children": []
  }
]} expandUrl="https://docs.medusajs.com/js-client/overview#expanding-fields"/>

#### Returns

<ParameterTypes parameters={[
  {
    "name": "ResponsePromise",
    "type": "ResponsePromise&#60;AdminPaymentProvidersList&#62;",
    "optional": false,
    "defaultValue": "",
    "description": "Resolves to the list of payment providers.",
    "expandable": false,
    "children": [
      {
        "name": "payment_providers",
        "type": "[PaymentProvider](../../entities/classes/entities.PaymentProvider.mdx)[]",
        "description": "An array of payment providers details.",
        "optional": false,
        "defaultValue": "",
        "expandable": false,
        "children": [
          {
            "name": "id",
            "type": "`string`",
            "description": "The ID of the payment provider as given by the payment service.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "is_installed",
            "type": "`boolean`",
            "description": "Whether the payment service is installed in the current version. If a payment service is no longer installed, the `is\\_installed` attribute is set to `false`.",
            "optional": false,
            "defaultValue": "true",
            "expandable": false,
            "children": []
          }
        ]
      }
    ]
  }
]} />

___

### listTaxProviders

Retrieve a list of available tax providers in a store.

#### Example

```ts
import Medusa from "@medusajs/medusa-js"
const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
// must be previously logged in or use api token
medusa.admin.store.listTaxProviders()
.then(({ tax_providers }) => {
  console.log(tax_providers.length);
})
```

#### Parameters

<ParameterTypes parameters={[
  {
    "name": "customHeaders",
    "type": "`Record<string, any>`",
    "description": "Custom headers to attach to the request.",
    "optional": false,
    "defaultValue": "{}",
    "expandable": false,
    "children": []
  }
]} expandUrl="https://docs.medusajs.com/js-client/overview#expanding-fields"/>

#### Returns

<ParameterTypes parameters={[
  {
    "name": "ResponsePromise",
    "type": "ResponsePromise&#60;AdminTaxProvidersList&#62;",
    "optional": false,
    "defaultValue": "",
    "description": "Resolves to the list of tax providers.",
    "expandable": false,
    "children": [
      {
        "name": "tax_providers",
        "type": "[TaxProvider](../../entities/classes/entities.TaxProvider.mdx)[]",
        "description": "An array of tax providers details.",
        "optional": false,
        "defaultValue": "",
        "expandable": false,
        "children": [
          {
            "name": "id",
            "type": "`string`",
            "description": "The ID of the tax provider as given by the tax service.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "is_installed",
            "type": "`boolean`",
            "description": "Whether the tax service is installed in the current version. If a tax service is no longer installed, the `is\\_installed` attribute is set to `false`.",
            "optional": false,
            "defaultValue": "true",
            "expandable": false,
            "children": []
          }
        ]
      }
    ]
  }
]} />

___

### retrieve

Retrieve the store's details.

#### Example

```ts
import Medusa from "@medusajs/medusa-js"
const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
// must be previously logged in or use api token
medusa.admin.store.retrieve()
.then(({ store }) => {
  console.log(store.id);
})
```

#### Parameters

<ParameterTypes parameters={[
  {
    "name": "customHeaders",
    "type": "`Record<string, any>`",
    "description": "Custom headers to attach to the request.",
    "optional": false,
    "defaultValue": "{}",
    "expandable": false,
    "children": []
  }
]} expandUrl="https://docs.medusajs.com/js-client/overview#expanding-fields"/>

#### Returns

<ParameterTypes parameters={[
  {
    "name": "ResponsePromise",
    "type": "ResponsePromise&#60;AdminExtendedStoresRes&#62;",
    "optional": false,
    "defaultValue": "",
    "description": "Resolves to the store's details.",
    "expandable": false,
    "children": [
      {
        "name": "store",
        "type": "[ExtendedStoreDTO](../../medusa/types/medusa.ExtendedStoreDTO.mdx)",
        "description": "Store details.",
        "optional": false,
        "defaultValue": "",
        "expandable": false,
        "children": [
          {
            "name": "created_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was created.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "currencies",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)[]",
            "description": "The details of the enabled currencies in the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)",
            "description": "The details of the store's default currency.",
            "optional": false,
            "defaultValue": "usd",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency_code",
            "type": "`string`",
            "description": "The three character currency code that is the default of the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_location_id",
            "type": "`string`",
            "description": "The location ID the store is associated with.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_sales_channel",
            "type": "[SalesChannel](../../entities/classes/entities.SalesChannel.mdx)",
            "description": "The details of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "created_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was created.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "deleted_at",
                "type": "`null` \\| `Date`",
                "description": "The date with timezone at which the resource was deleted.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "description",
                "type": "`null` \\| `string`",
                "description": "The description of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "id",
                "type": "`string`",
                "description": "The sales channel's ID",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "is_disabled",
                "type": "`boolean`",
                "description": "Specify if the sales channel is enabled or disabled.",
                "optional": false,
                "defaultValue": "false",
                "expandable": false,
                "children": []
              },
              {
                "name": "locations",
                "type": "[SalesChannelLocation](../../entities/classes/entities.SalesChannelLocation.mdx)[]",
                "description": "The details of the stock locations related to the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": true,
                "children": []
              },
              {
                "name": "metadata",
                "type": "`null` \\| `Record<string, unknown>`",
                "description": "An optional key-value map with additional details",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The name of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "updated_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was updated.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_sales_channel_id",
            "type": "`null` \\| `string`",
            "description": "The ID of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "id",
            "type": "`string`",
            "description": "The store's ID",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "invite_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Invite links from",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "metadata",
            "type": "`null` \\| `Record<string, unknown>`",
            "description": "An optional key-value map with additional details",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "name",
            "type": "`string`",
            "description": "The name of the Store - this may be displayed to the Customer.",
            "optional": false,
            "defaultValue": "Medusa Store",
            "expandable": false,
            "children": []
          },
          {
            "name": "payment_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Payment links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the payment's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "swap_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Swap links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the Swap's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "updated_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was updated.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "feature_flags",
            "type": "[FeatureFlagsResponse](../../medusa/types/medusa.FeatureFlagsResponse.mdx)",
            "description": "The feature flags enabled in the store's backend.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": [
              {
                "name": "key",
                "type": "`string`",
                "description": "",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "value",
                "type": "`boolean` \\| `Record<string, boolean>`",
                "description": "",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "fulfillment_providers",
            "type": "[FulfillmentProvider](../../entities/classes/entities.FulfillmentProvider.mdx)[]",
            "description": "The store's fulfillment providers.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": [
              {
                "name": "id",
                "type": "`string`",
                "description": "The ID of the fulfillment provider as given by the fulfillment service.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "is_installed",
                "type": "`boolean`",
                "description": "Whether the fulfillment service is installed in the current version. If a fulfillment service is no longer installed, the `is\\_installed` attribute is set to `false`.",
                "optional": false,
                "defaultValue": "true",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "modules",
            "type": "[ModulesResponse](../../medusa/types/medusa.ModulesResponse.mdx)",
            "description": "The modules installed in the store's backend.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "payment_providers",
            "type": "[PaymentProvider](../../entities/classes/entities.PaymentProvider.mdx)[]",
            "description": "The store's payment providers.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": [
              {
                "name": "id",
                "type": "`string`",
                "description": "The ID of the payment provider as given by the payment service.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "is_installed",
                "type": "`boolean`",
                "description": "Whether the payment service is installed in the current version. If a payment service is no longer installed, the `is\\_installed` attribute is set to `false`.",
                "optional": false,
                "defaultValue": "true",
                "expandable": false,
                "children": []
              }
            ]
          }
        ]
      }
    ]
  }
]} />

___

### update

Update the store's details.

#### Example

```ts
import Medusa from "@medusajs/medusa-js"
const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
// must be previously logged in or use api token
medusa.admin.store.update({
  name: "Medusa Store"
})
.then(({ store }) => {
  console.log(store.id);
})
```

#### Parameters

<ParameterTypes parameters={[
  {
    "name": "payload",
    "type": "[AdminPostStoreReq](../../medusa/classes/medusa.AdminPostStoreReq.mdx)",
    "description": "The attributes to update in the store.",
    "optional": false,
    "defaultValue": "",
    "expandable": false,
    "children": [
      {
        "name": "currencies",
        "type": "`string`[]",
        "description": "Array of available currencies in the store. Each currency is in 3 character ISO code format.",
        "optional": true,
        "defaultValue": "",
        "expandable": false,
        "children": []
      },
      {
        "name": "default_currency_code",
        "type": "`string`",
        "description": "The default currency code of the Store.",
        "optional": true,
        "defaultValue": "",
        "expandable": false,
        "children": []
      },
      {
        "name": "invite_link_template",
        "type": "`string`",
        "description": "A template for invite links - use `&#123;&#123;invite\\_token&#125;&#125;` to insert the invite token",
        "optional": true,
        "defaultValue": "",
        "expandable": false,
        "children": []
      },
      {
        "name": "metadata",
        "type": "`Record<string, unknown>`",
        "description": "An optional set of key-value pairs with additional information.",
        "optional": true,
        "defaultValue": "",
        "expandable": false,
        "children": []
      },
      {
        "name": "name",
        "type": "`string`",
        "description": "The name of the Store",
        "optional": true,
        "defaultValue": "",
        "expandable": false,
        "children": []
      },
      {
        "name": "payment_link_template",
        "type": "`string`",
        "description": "A template for payment links - use `&#123;&#123;cart\\_id&#125;&#125;` to insert the Cart ID",
        "optional": true,
        "defaultValue": "",
        "expandable": false,
        "children": []
      },
      {
        "name": "swap_link_template",
        "type": "`string`",
        "description": "A template for Swap links - use `&#123;&#123;cart\\_id&#125;&#125;` to insert the Swap Cart ID",
        "optional": true,
        "defaultValue": "",
        "expandable": false,
        "children": []
      }
    ]
  },
  {
    "name": "customHeaders",
    "type": "`Record<string, any>`",
    "description": "Custom headers to attach to the request.",
    "optional": false,
    "defaultValue": "{}",
    "expandable": false,
    "children": []
  }
]} expandUrl="https://docs.medusajs.com/js-client/overview#expanding-fields"/>

#### Returns

<ParameterTypes parameters={[
  {
    "name": "ResponsePromise",
    "type": "ResponsePromise&#60;AdminStoresRes&#62;",
    "optional": false,
    "defaultValue": "",
    "description": "Resolves to the store's details.",
    "expandable": false,
    "children": [
      {
        "name": "store",
        "type": "[Store](../../entities/classes/entities.Store.mdx)",
        "description": "Store details.",
        "optional": false,
        "defaultValue": "",
        "expandable": false,
        "children": [
          {
            "name": "created_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was created.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "currencies",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)[]",
            "description": "The details of the enabled currencies in the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency",
            "type": "[Currency](../../entities/classes/entities.Currency.mdx)",
            "description": "The details of the store's default currency.",
            "optional": false,
            "defaultValue": "usd",
            "expandable": true,
            "children": [
              {
                "name": "code",
                "type": "`string`",
                "description": "The 3 character ISO code for the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "includes_tax",
                "type": "`boolean`",
                "description": "Whether the currency prices include tax",
                "optional": true,
                "defaultValue": "false",
                "expandable": false,
                "featureFlag": "tax_inclusive_pricing",
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The written name of the currency",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol",
                "type": "`string`",
                "description": "The symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "symbol_native",
                "type": "`string`",
                "description": "The native symbol used to indicate the currency.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_currency_code",
            "type": "`string`",
            "description": "The three character currency code that is the default of the store.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_location_id",
            "type": "`string`",
            "description": "The location ID the store is associated with.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "default_sales_channel",
            "type": "[SalesChannel](../../entities/classes/entities.SalesChannel.mdx)",
            "description": "The details of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": true,
            "children": [
              {
                "name": "created_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was created.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "deleted_at",
                "type": "`null` \\| `Date`",
                "description": "The date with timezone at which the resource was deleted.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "description",
                "type": "`null` \\| `string`",
                "description": "The description of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "id",
                "type": "`string`",
                "description": "The sales channel's ID",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "is_disabled",
                "type": "`boolean`",
                "description": "Specify if the sales channel is enabled or disabled.",
                "optional": false,
                "defaultValue": "false",
                "expandable": false,
                "children": []
              },
              {
                "name": "locations",
                "type": "[SalesChannelLocation](../../entities/classes/entities.SalesChannelLocation.mdx)[]",
                "description": "The details of the stock locations related to the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": true,
                "children": []
              },
              {
                "name": "metadata",
                "type": "`null` \\| `Record<string, unknown>`",
                "description": "An optional key-value map with additional details",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "name",
                "type": "`string`",
                "description": "The name of the sales channel.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              },
              {
                "name": "updated_at",
                "type": "`Date`",
                "description": "The date with timezone at which the resource was updated.",
                "optional": false,
                "defaultValue": "",
                "expandable": false,
                "children": []
              }
            ]
          },
          {
            "name": "default_sales_channel_id",
            "type": "`null` \\| `string`",
            "description": "The ID of the store's default sales channel.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "id",
            "type": "`string`",
            "description": "The store's ID",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "invite_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Invite links from",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "metadata",
            "type": "`null` \\| `Record<string, unknown>`",
            "description": "An optional key-value map with additional details",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "name",
            "type": "`string`",
            "description": "The name of the Store - this may be displayed to the Customer.",
            "optional": false,
            "defaultValue": "Medusa Store",
            "expandable": false,
            "children": []
          },
          {
            "name": "payment_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Payment links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the payment's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "swap_link_template",
            "type": "`null` \\| `string`",
            "description": "A template to generate Swap links from. Use &#123;&#123;cart\\_id&#125;&#125; to include the Swap's `cart\\_id` in the link.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          },
          {
            "name": "updated_at",
            "type": "`Date`",
            "description": "The date with timezone at which the resource was updated.",
            "optional": false,
            "defaultValue": "",
            "expandable": false,
            "children": []
          }
        ]
      }
    ]
  }
]} />
