# Search proposals

Use the **searchProposals** method via JSON-RPC APIv6 to find a specific proposal or quote.

## Request parameters

<table><thead><tr><th width="153.2000732421875">Parameter</th><th>Type / Description</th></tr></thead><tbody><tr><td><code>sessionId</code></td><td><p><strong>Required (string)</strong></p><p>Unique 2Checkout session ID code.</p></td></tr><tr><td><code>Name</code></td><td><p><strong>Optional (string)</strong></p><p>Proposal name.</p></td></tr><tr><td><code>Email</code></td><td><p><strong>Optional (string)</strong></p><p>The bill to or sell to email.</p></td></tr><tr><td><code>CreatedBy</code></td><td><p><strong>Optional (string)</strong></p><p>The unique external system user identifier.</p></td></tr><tr><td><code>ModifiedBy</code></td><td><p><strong>Optional (string)</strong></p><p>The unique external system user identifier.</p></td></tr><tr><td><code>Source</code></td><td><p><strong>Optional (string)</strong></p><p>The source from where the proposal was created.</p></td></tr><tr><td><code>CreatedAfter</code></td><td><p><strong>Optional (string)</strong></p><p>The UTC date and time in ISO 8601 format.</p></td></tr><tr><td><code>CreatedBefore</code></td><td><p><strong>Optional (string)</strong></p><p>The UTC date and time in ISO 8601 format.</p></td></tr><tr><td><code>ModifiedAfter</code></td><td><p><strong>Optional (string)</strong></p><p>The UTC date and time in ISO 8601 format.</p></td></tr><tr><td><code>ModifiedBefore</code></td><td><p><strong>Optional (string)</strong></p><p>The UTC date and time in ISO 8601 format.</p></td></tr><tr><td><code>Locked</code></td><td><p><strong>Optional (boolean)</strong></p><p>Retrieve proposals that are locked or not.<br>Possible values:</p><ul><li>True</li><li>False</li></ul></td></tr><tr><td><code>Offset</code></td><td><p><strong>Required (integer)</strong></p><p>The offset at which the proposals should be returned. Default value: 0.</p></td></tr><tr><td><code>Limit</code></td><td><p><strong>Required (integer)</strong></p><p>The maximum number of proposals to return. Default value: 10.</p></td></tr><tr><td><code>LinkId</code></td><td><p><strong>Optional (string)</strong></p><p>The link id for any status.</p></td></tr></tbody></table>

### Request sample

```php
<?php

require ('PATH_TO_AUTH');

$searchParameters = new stdClass();
$searchParameters->Name = "My Proposal Name";
$searchParameters->Email = "example@email.com";
$searchParameters->CreatedBy = "createUser";
$searchParameters->ModifiedBy = "modifyUser";
$searchParameters->Source = "MERCHANT_API";
$searchParameters->CreatedAfter = "2020-01-01T00:00:00+00:00";
$searchParameters->CreatedBefore = "2020-12-31T23:59:59+00:00";
$searchParameters->ModifiedAfter = "2020-01-01T00:00:00+00:00";
$searchParameters->ModifiedBefore = "2020-12-31T23:59:59+00:00";
$searchParameters->Locked = false;
$searchParameters->Offset = 0;
$searchParameters->Limit = 10;

$jsonRpcRequest = new stdClass();
$jsonRpcRequest->jsonrpc = '2.0';
$jsonRpcRequest->method = 'searchProposals';
$jsonRpcRequest->params = array($sessionID, $searchParameters);
$jsonRpcRequest->id = $i++;

try {
    $result = callRPC($jsonRpcRequest, $host);
    echo "Proposal: </br>",
    var_dump($result);
}
catch (SoapFault $e) {
    echo "Could not fetch proposal: " . $e->getMessage();
    exit;
}
```

## Response

The **searchProposals** call via JSON-RPC APIv6 returns a list of [Proposal](/json-rpc-api-reference/json-rpc-api-6.0/api-requests/proposal-microservice.md) objects.


---

# 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.2checkout.com/json-rpc-api-reference/json-rpc-api-6.0/api-requests/proposal-microservice/search-proposals.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.
