---
title: "Export the current board position as a FEN-style setup string, in the form the variant's own frontmatter declares its starting position. Card, tile and dice games have no board position to export."
method: POST
path: "/api/tools/play_export_fen"
---

# Export the current board position as a FEN-style setup string, in the form the variant's own frontmatter declares its starting position. Card, tile and dice games have no board position to export.

`POST /api/tools/play_export_fen`

## Request

- Base URL: `https://tools.moddable.games`
- URL: `https://tools.moddable.games/api/tools/play_export_fen`
- Auth: none declared

## Request body

- object
  - `state` object, required: Game state object from play_create_game or play_apply_move

## Response `200`

Tool result

---

[API](https://skmtc.dev/moddable/apis/moddable-games-tools.md) · [All operations](https://skmtc.dev/moddable/apis/moddable-games-tools/llms.txt) · [OpenAPI document](https://skmtc.dev/moddable/apis/moddable-games-tools/revisions/637a0b62cb9a?raw)
