# Integrate Speakeasy with ReadMe

---

Autogenerated code snippets from Speakeasy SDKs can be integrated directly into a ReadMe documentation site.

## Prerequisites

To integrate ReadMe with Speakeasy, the following is required:

- A [ReadMe project created](https://docs.readme.com/main/docs/quickstart-guide#step-1-creating-your-project).
- A Speakeasy-generated SDK with a configured [automated code sample URL](/docs/sdk-docs/code-samples/automated-code-sample-urls).

## Setting up the integration

### Configure `workflow.yaml` for ReadMe

To display code samples from Speakeasy SDKs in ReadMe, update the `workflow.yaml` file to support their proprietary OpenAPI extension.

In the SDK target configuration, set the `codeSamples.style` field to `readme`:

```yaml filename=".speakeasy/workflow.yaml"
targets:
  my-target:
    target: typescript
    codeSamples:
      # !mark(1:2)
      style: readme
      langOverride: javascript # see note below
      registry:
        location: registry.speakeasy.com/...
      blocking: false
    ...
```

<Callout title="Note for TypeScript">
  If the `target` value is set to `typescript`, the `langOverride` field must be
  set to `javascript` or generated code samples will **not** be displayed in
  ReadMe.
  {` `}
  If `target` is **not** set to `typescript`, then `langOverride` should be set to
  `auto-detect`.
</Callout>

### Upload the combined spec URL to ReadMe

In the [ReadMe dashboard](https://dash.readme.com), open the project.

Click the **API Reference** tab, then click **&plus; New API Definition**.

Paste the combined spec URL from Speakeasy into the text input below **Import from URL**, then click **Import**.

Speakeasy-generated code snippets are now available in the ReadMe project's **API Reference** section.

## Next steps

For help customizing ReadMe API references generated from OpenAPI documents, see the [ReadMe OpenAPI support documentation](https://docs.readme.com/main/docs/openapi).
