# SessionError

This class represents the errors available for the WatchTogether session.

## Field Summary <a href="#field-summary" id="field-summary"></a>

| Type   | Field                     |
| ------ | ------------------------- |
| Int    | code - *Error code*       |
| String | name - *Error name*       |
| String | message - *Error message* |

## Public Constructor Summary <a href="#public-constructor-summary" id="public-constructor-summary"></a>

| Type | Methods                                                               | Parameters                                                                                            |
| ---- | --------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- |
| void | SessionError(final int code, final String name, final String message) | <ul><li>code - Error number code</li><li> name - Error name</li><li>message - Error message</li></ul> |

## Error codes <a href="#error-codes" id="error-codes"></a>

| Code | Error                            | Description                                                                                    |
| ---- | -------------------------------- | ---------------------------------------------------------------------------------------------- |
| -1   | UNKNOWN\_ERROR                   | Internal server error                                                                          |
| 999  | GENERIC\_ERROR\_CODE             | The request is not supported                                                                   |
| 901  | GENERIC\_CONNECTION\_ERROR       | The client closed the connection in the middle of the process of joining the room              |
| 801  | TRANSPORT\_REQUEST\_ERROR\_CODE  | Failed to make a request to the media node                                                     |
| 802  | TRANSPORT\_RESPONSE\_ERROR\_CODE | Invalid response from media node                                                               |
| 803  | TRANSPORT\_ERROR\_CODE           | <ul><li>The request method is not supported</li><li>Invalid or missing request field</li></ul> |

## Media Error codes <a href="#media-error-codes" id="media-error-codes"></a>

| Code | Error                                 | Description                                                                                                                                                                   |
| ---- | ------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 303  | MEDIA\_ENDPOINT\_ERROR\_CODE          | <ul><li>Already subscribed to media stream from target client</li><li>SDP exchange for this media stream is already in progress</li><li>Timeout during SDP exchange</li></ul> |
| 308  | MEDIA\_AUDIO\_PERMISSION\_ERROR\_CODE | <ul><li>Microphone permission is not granted</li></ul>                                                                                                                        |
| 309  | MEDIA\_VIDEO\_PERMISSION\_ERROR\_CODE | <ul><li>Camera permission is not granted</li></ul>                                                                                                                            |

## Session Error codes <a href="#session-error-codes" id="session-error-codes"></a>

| Code | Error                          | Description                                                                                                                                                                             |
| ---- | ------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 206  | SESSION\_IS\_FULL\_ERROR\_CODE | Exceeded limit of streaming participants in the room                                                                                                                                    |
| 203  | SESSION\_CLOSED\_ERROR\_CODE   |                                                                                                                                                                                         |
| 201  | SESSION\_GENERIC\_ERROR\_CODE  | <p></p><ul><li>Unable to handle the request as the Session is locked </li><li>Active requests counter underflow (Internal server logic)</li><li>The Session is already locked</li></ul> |

## User Error codes <a href="#user-error-codes" id="user-error-codes"></a>

| Code | Error                                    | Description                                                                                                                                                                                                          |
| ---- | ---------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 106  | USER\_NOT\_AUTHORIZED\_ERROR\_CODE       | <ul><li>Attempting to send synchronization data while not having a synchronizer role</li><li>Invalid oldParticipantSecret during reconnection</li></ul>                                                              |
| 105  | USER\_NOT\_STREAMING\_ERROR\_CODE        | <ul><li>Attempting to start a stream with no video and audio</li><li>Attempting to send SDP response when there was no offer</li><li>Attempting to subscribe to a client that did not publish anything yet</li></ul> |
| 104  | EXISTING\_USER\_IN\_SESSION\_ERROR\_CODE | A Participant tries to join a Session with a name that already exists                                                                                                                                                |
| 103  | USER\_CLOSED\_ERROR\_CODE                | <ul><li>Source or target user has left the Session during the media subscription process</li><li>Target user has left the Session during SDP exchange</li></ul>                                                      |
| 102  | USER\_NOT\_FOUND\_ERROR\_CODE            | <ul><li>Attempting to execute request before joining the Session</li><li>Addressing client that is not in the Session</li></ul>                                                                                      |
| 101  | USER\_GENERIC\_ERROR\_CODE               | <ul><li>Invalid participant type</li><li>Target client is not is not available while in the process of media (un)subscription</li><li>ICE candidates queue overflow</li></ul>                                        |


---

# 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://documentation.sceenic.co/watch-together-sdk/sscale-confluence-api-references/android-reference-new/sessionerror.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.
