# Answer the website’s form

> Submit the account holder’s answers to the current website sign-in form.

Source: https://docs.fous.com/api-reference/submitConnectionStep

`POST /v1/connections/attempts/{attempt_id}/submit`

Sends the person’s answers to the current form: fields by field id, or choice for an alternative. Answers with the attempt once the website responded (wait) or as it stands.

Authentication: `Authorization: Bearer $FOUS_API_KEY`.

## Path parameters

- `attempt_id` (string, required)

## Query parameters

- `wait` (integer): Default 0.

## Request body

Required. JSON.

- `challenge_id` (string, required)
- `step_id` (string, required)
- `fields` (object)
- `choice` (string)

## Response 200

Success

- `success` (true, required)
- `data` (ConnectionAttempt, required): One sign-in, step by step. challenge: the website asks for something, described in form; submit the answers. working: wait. verified: confirm it. ready: the account is connected. failed: notice says why, can_retry whether another method can be tried.

## Errors

Every error uses the Error schema: branch on `error.code`. Codes are listed at https://docs.fous.com/guides/errors.

- 400
- 401 (headers: WWW-Authenticate)
- 402
- 403
- 404
- 408
- 409
- 410
- 413
- 422
- 429 (headers: Retry-After)
- 500
- 502
- 503 (headers: Retry-After)
- 504

## Example request

```bash
curl 'https://api.fous.com/v1/connections/attempts/{attempt_id}/submit?wait=60' \
  -H "Authorization: Bearer $FOUS_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{"challenge_id":"11111111-1111-4111-8111-111111111111","step_id":"22222222-2222-4222-8222-222222222222","fields":{"email":"you@example.com","password":"your-password"}}'
```
