NetSuite REST icon

NetSuite REST

Call NetSuite SuiteTalk REST operations.

Actions979

Opportunity → Get list of records

AI-generated

Summary

Retrieve a list of Opportunity records from NetSuite with optional filtering, pagination, and asynchronous request support.

Inputs

  • Debug Mode — Enable to include the full HTTP request and response details in the output for debugging purposes.
  • Limit — Specify the maximum number of Opportunity records to return in a single page of results.
  • Offset — Specify the number of Opportunity records to skip before starting to return results, used for paging.
  • Prefer — Set to 'respond-async' to request asynchronous execution of the API call; otherwise synchronous execution is used.
  • Q — A search query string to filter the returned Opportunity records.
  • X - Net Suite - Idempotency - Key — A UUID string used to ensure the asynchronous request executes only once. Ignored if the request is synchronous.

Output shape

The operation returns a list of Opportunity records retrieved from NetSuite. If Debug Mode is enabled, output also includes full request and response details. The output may reflect a single page of results as limited by the 'Limit' and 'Offset' parameters.

Pagination is controlled via 'Limit' and 'Offset' parameters. The 'Prefer' header enables asynchronous request handling; if 'respond-async' is used, the response indicates asynchronous processing. The 'X-NetSuite-Idempotency-Key' is only respected in asynchronous requests to avoid duplicate execution.

Examples

Example 1: Fetch the first 10 Opportunity records synchronously with debug information.

'Limit' set to 10, 'Debug Mode' enabled, 'Prefer' left empty or default.

Example 2: Asynchronously execute a filtered Opportunity search with idempotency key to prevent duplicate processing.

'Q' set to a search term, 'Prefer' set to 'respond-async', 'X - Net Suite - Idempotency - Key' set to a UUID string.

Discussion