# Simulate Device Connection

* [Request Parameters](#request-parameters)
* [Response](#response)

Simulates connecting a device to Seam. Only applicable for [sandbox devices](https://docs.seam.co/latest/core-concepts/workspaces#sandbox-workspaces). See also [Testing Your App Against Device Disconnection and Removal](https://docs.seam.co/latest/core-concepts/devices/testing-your-app-against-device-disconnection-and-removal).

{% tabs %}
{% tab title="JavaScript" %}
Simulates connecting a device to Seam.

**Code:**

```javascript
await seam.devices.simulate.connect({
  device_id: "5d703d4f-523f-42af-9439-618415ca651f",
});
```

**Output:**

```javascript
// void
```

{% endtab %}

{% tab title="cURL" %}
Simulates connecting a device to Seam.

**Code:**

```curl
curl --include --request POST "https://connect.getseam.com/devices/simulate/connect" \
  --header "Authorization: Bearer $SEAM_API_KEY" \
  --json @- <<EOF
{
  "device_id": "5d703d4f-523f-42af-9439-618415ca651f"
}
EOF
```

**Output:**

```curl
{}
```

{% endtab %}

{% tab title="Python" %}
Simulates connecting a device to Seam.

**Code:**

```python
seam.devices.simulate.connect(device_id="5d703d4f-523f-42af-9439-618415ca651f")
```

**Output:**

```python
None
```

{% endtab %}

{% tab title="Ruby" %}
Simulates connecting a device to Seam.

**Code:**

```ruby
seam.devices.simulate.connect(device_id: "5d703d4f-523f-42af-9439-618415ca651f")
```

**Output:**

```ruby
nil
```

{% endtab %}

{% tab title="PHP" %}
Simulates connecting a device to Seam.

**Code:**

```php
$seam->devices->simulate->connect(
    device_id: "5d703d4f-523f-42af-9439-618415ca651f",
);
```

**Output:**

```php
```

{% endtab %}

{% tab title="Seam CLI" %}
Simulates connecting a device to Seam.

**Code:**

```seam_cli
seam devices simulate connect --device_id "5d703d4f-523f-42af-9439-618415ca651f"
```

**Output:**

```seam_cli
{}
```

{% endtab %}
{% endtabs %}

<details>

<summary>Authentication Methods</summary>

* API key
* Client session token
* Personal access token\
  Must also include the `seam-workspace` header in the request.

To learn more, see [Authentication](https://docs.seam.co/latest/api/authentication).

</details>

## Request Parameters

**`device_id`** *String* (Required)

ID of the device that you want to simulate connecting to Seam.

***

## Response

{% hint style="success" %}
Returns: **void**
{% endhint %}


---

# 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.seam.co/latest/api/devices/simulate/connect.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.
