# readFile()

Canonical URL: https://developers.iagenify.com/pt/sdk/ref/agents/skills/read-file/
Language: pt

`api.agents.skills.readFile(name, file) → Promise<File>`

Uno dei documenti extra di una aptitudini — un template, una lista de control, una tabla de reference. Compatibilitè informatica solamente: una aptitudè de contatè un documento uni.

Status: skills only · computer only · listed by get()

```javascript
const skill = await api.agents.skills.get("release-notes");
console.log(skill.files);        // ["template.md", "examples.md"]

const template = await api.agents.skills.readFile("release-notes", "template.md");
```

## Por què i files extra existen {#why}

Un template o una lunga referencia non è dentro di lui, il corpo è in prompt una vez che la habilidad è caricata, e un file non costa nulla fino a quando è aperto.

## L'agente le apre de la medesima forma {#agent}

`skill { name, file }` — i nomes de files sono listati quando la abilità carica.

## Erros {#errors}

| Código | Status | Quando |
| --- | --- | --- |
| not_a_skill | 400 | Invocat in biblioteca subagents. Solo le aptitudinis ha dosi. |
| path_not_found | 404 | Nessun disco qui, o tal file nel dossier del distret. |

> **Un account hability responses path_not_found**
>
> E un documentu unico — non c'è nòs a parte. Il messaggio lo dice invecèt di insinuare che il file era perdut.

- [get()](/pt/sdk/ref/agents/skills/get): De da cui proven i nomi de file.
- [aptitud](/pt/sdk/agent/tools/skill): La parte del agent.

```python
skill = api.agents.skills.get("release-notes")
print(skill.get("files"))        # ["template.md", "examples.md"]

template = api.agents.skills.read_file("release-notes", "template.md")
```
