# Connect to RedesIA (MCP server)

RedesIA plans and produces social media content (Instagram, Facebook and LinkedIn) for a business. This address is its MCP server. If a person asked you to set it up, everything you need is below — do the technical steps yourself and do not ask the person for a client id, a client secret, an API key or which kind of authentication to use. They only sign in to RedesIA and approve access in their browser.

## Connection details

- Server URL: https://app.redes-ia.com/mcp
- Transport: Streamable HTTP (POST JSON-RPC). No sessions, no server-sent events.
- Authentication: OAuth 2.1, authorization code flow with PKCE, as a public client (no client secret).
- PKCE method: S256 (required).
- Scopes: read, create, publish. Ask for all three unless the person wants a read-only connection (`read`); the person can change what they grant on the consent screen.
- Tokens: send `Authorization: Bearer <access_token>` on every request; renew with the refresh token.

## How to connect (the standard MCP authorization flow)

1. Call the server URL without a token. You get 401 with a `WWW-Authenticate` header whose `resource_metadata` is https://app.redes-ia.com/.well-known/oauth-protected-resource/mcp.
2. Read the authorization server metadata (https://app.redes-ia.com/.well-known/oauth-authorization-server) for the endpoints.
3. Register yourself — dynamic client registration (RFC 7591): POST https://app.redes-ia.com/oauth/register with JSON `{"client_name": "<your name>", "redirect_uris": ["<your redirect address>"], "grant_types": ["authorization_code", "refresh_token"], "response_types": ["code"], "token_endpoint_auth_method": "none"}`. The answer contains your `client_id`. Use your own client's redirect address (https, or http only for localhost). Do this automatically; it needs no account and no secret.
4. Send the person's browser to https://app.redes-ia.com/oauth/authorize with `response_type=code`, your `client_id`, `redirect_uri`, `code_challenge` and `code_challenge_method=S256`, `scope`, `state` and `resource=https://app.redes-ia.com/mcp`. They sign in to RedesIA (or create a free account) and approve what you may do.
5. Exchange the code at https://app.redes-ia.com/oauth/token (form-encoded: `grant_type=authorization_code`, `code`, `code_verifier`, `redirect_uri`, `client_id`). No client secret.
6. Call `get_account` first, then use the tools. The server tells you how each one works.

## If your platform does not do this by itself

Some assistants only offer a connector form. Fill it like this and leave everything else empty:

- URL: https://app.redes-ia.com/mcp
- Authentication: OAuth (not an API key, not a header token)
- Client ID / client secret: leave empty if the form lets you — the server registers clients automatically. If it insists on a client id, register one yourself with step 3 and use that; never ask the person to invent one.

## Things to know before you use it

- Anything that spends credits is quoted first and needs the person’s explicit yes (`confirm_spend`).
- Everything you create is a draft. Nothing is scheduled or published unless the person asks (`publish_post` shows a preview first).
- Drawing pictures can take up to 2 minutes: use a long request timeout and do not retry while a call runs.

Human documentation: https://redes-ia.com/en/connect-ai-assistant
