# app.didpic.chat.findOrCreateConversation

> Published by [lexicons.didpic.app](https://lexicon.garden/identity/did:plc:an2jtp4jgkkbtmwfzhpbxawd)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:an2jtp4jgkkbtmwfzhpbxawd/app.didpic.chat.findOrCreateConversation)
- [Documentation](https://lexicon.garden/lexicon/did:plc:an2jtp4jgkkbtmwfzhpbxawd/app.didpic.chat.findOrCreateConversation/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:an2jtp4jgkkbtmwfzhpbxawd/app.didpic.chat.findOrCreateConversation/examples)

## Definitions

### `app.didpic.chat.findOrCreateConversation`

**Type**: `procedure`

Start a conversation, or return an existing 1:1 with the same person.

#### Input

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `participantDids` | `array` | Yes |  |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `conversationId` | `string` | Yes |  |
| `created` | `boolean` | Yes | False if an existing conversation was reused. |

#### Errors

- **Blocked**
- **InvalidRequest**

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Start a conversation, or return an existing 1:1 with the same person.",
      "errors": [
        {
          "name": "Blocked"
        },
        {
          "name": "InvalidRequest"
        }
      ],
      "input": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "participantDids": {
              "items": {
                "type": "string"
              },
              "maxLength": 9,
              "minLength": 1,
              "type": "array"
            }
          },
          "required": [
            "participantDids"
          ],
          "type": "object"
        }
      },
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "conversationId": {
              "type": "string"
            },
            "created": {
              "description": "False if an existing conversation was reused.",
              "type": "boolean"
            }
          },
          "required": [
            "conversationId",
            "created"
          ],
          "type": "object"
        }
      },
      "type": "procedure"
    }
  },
  "id": "app.didpic.chat.findOrCreateConversation",
  "lexicon": 1
}
```
