---
editLink: false
lastUpdated: false
---

[@salesforce/b2c-tooling-sdk](../../modules.md) / [docs](../index.md) / readSchema

# Function: readSchema()

> **readSchema**(`id`): \{ `content`: `string`; `entry`: [`SchemaEntry`](../interfaces/SchemaEntry.md); `path`: `string`; \} \| `null`

Defined in: [packages/b2c-tooling-sdk/src/docs/schema.ts:69](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/67fb8580ac3c5b372617ee3ec3fc8f2bc9f16174/packages/b2c-tooling-sdk/src/docs/schema.ts#L69)

Read a schema by its exact ID.

## Parameters

### id

`string`

The exact schema ID to look up

## Returns

\{ `content`: `string`; `entry`: [`SchemaEntry`](../interfaces/SchemaEntry.md); `path`: `string`; \} \| `null`

An object containing the schema entry, file content, and file path; or null if the schema ID is not found
