# Api

The Openstad API is a REST based api. It manages the data of the submitted ideas, votes, etc. It is the interface to the OpenStad data that is stored in a MySQL database. It uses the [Sequelize](https://sequelize.org/) framework for Object modeling.

## Resources

* [Site](/openstad/technical/api/resource-site.md)
* [Idea](/openstad/technical/api/resource-idea.md)
* [Argument](/openstad/technical/api/resource-argument.md)
* [Vote](/openstad/technical/api/resource-vote.md)
* [Article](/openstad/technical/api/resource-article.md)
* [Newsletter Signup](/openstad/technical/api/resource-newslettersignup.md)
* [User](/openstad/technical/api/resource-user.md)

## Authentication and JWT

Authentication of API call is done with a JWT. The API issues one after connecting with the auth server via the oAuth2 protocol.

See:

* [Auth](/openstad/technical/api/auth.md)
* [Sequelize authorization](/openstad/technical/api/sequelize-authorization.md)

## Miscellaneous

* [Pagination and search](/openstad/technical/api/pagination-and-search.md)
* [Email settings](/openstad/technical/api/email.md)
* [Database migrations](/openstad/technical/api/db-changes.md)
* [Configuration](/openstad/technical/api/api-configuration.md)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.openstad.org/openstad/technical/api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
