Hierarchy

  • RUMApi

Constructors

Properties

configuration: Configuration
requestFactory: RUMApiRequestFactory
responseProcessor: RUMApiResponseProcessor

Methods

  • Retrieves the content of a specific JavaScript source map file. Provide either debug_id with a UUID, or all three of filename, service, and version. When debug_id is provided, filename, service, and version are not required and are ignored.

    Examples: the following commands use the US1 API host. Replace the host with the API host for your site, and the filename, service, version, and debug ID with values from your organization. Use --get so curl sends the parameters in the query string.

    1. Retrieve a source map by debug ID

    Provide debug_id with a UUID. No filename, service, or version is required.

    curl -sS --get "https://api.datadoghq.com/api/v2/sourcemaps" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
    --data-urlencode "debug_id=00000000-0000-4000-8000-000000000001"

    2. Retrieve a source map by service and version

    Provide filename together with service and version.

    curl -sS --get "https://api.datadoghq.com/api/v2/sourcemaps" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
    --data-urlencode "filename=js/bundle.min.js.map" \
    --data-urlencode "service=my-web-service" \
    --data-urlencode "version=1.0.0"

    Parameters

    Returns Promise<SourcemapFileResponse>

  • Retrieves a paginated list of source maps. Send filters as query parameters, not in a JSON request body. mapkind defaults to js.

    For JavaScript source maps, choose one of the three request shapes below.

    Examples: the following commands use the US1 API host. Replace the host with the API host for your site, and the service, version, debug ID, and cursor with values from your organization. Use --get so curl sends the filters in the query string; -X GET with --data-urlencode sends them in the request body instead.

    1. List by service and version

    Provide both filter[service] and filter[version] to search source maps indexed by service and version. Omit search_by.

    Pagination: prefer cursor pagination. Omit page[after] and page[number] on the first request. To get the next page, pass meta.page.next_cursor as page[after], keeping the same filters. Continue until meta.page.has_more_results is false. Do not decode or modify the cursor. Legacy page-number pagination is also supported, starting at page[number]=1.

    curl -sS --get "https://api.datadoghq.com/api/v2/sourcemaps/list" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
    --data-urlencode "mapkind=js" \
    --data-urlencode "filter[service]=my-web-service" \
    --data-urlencode "filter[version]=1.0.0" \
    --data-urlencode "page[size]=10"

    2. Find a specific JavaScript debug ID

    Provide filter[debug_id] with a UUID. Service and version filters are not required. Omit search_by.

    Pagination: the lookup returns at most one result, so no pagination is needed. page[after] is not supported.

    curl -sS --get "https://api.datadoghq.com/api/v2/sourcemaps/list" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
    --data-urlencode "mapkind=js" \
    --data-urlencode "filter[debug_id]=00000000-0000-4000-8000-000000000001"

    3. Browse source maps indexed by debug ID

    Set search_by=debug_id without specifying a debug ID. Do not send service, version, or filename filters in this mode.

    Pagination: this mode requires cursor pagination; page[number] is not supported. Omit page[after] on the first request. To get the next page, pass meta.page.next_cursor as page[after], keeping the same search mode and filters. Continue until meta.page.has_more_results is false. Do not decode or modify the cursor.

    First page:

    curl -sS --get "https://api.datadoghq.com/api/v2/sourcemaps/list" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
    --data-urlencode "mapkind=js" \
    --data-urlencode "search_by=debug_id" \
    --data-urlencode "page[size]=10"

    Next page:

    curl -sS --get "https://api.datadoghq.com/api/v2/sourcemaps/list" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
    --data-urlencode "mapkind=js" \
    --data-urlencode "search_by=debug_id" \
    --data-urlencode "page[size]=10" \
    --data-urlencode "page[after]=<meta.page.next_cursor>"

    For other map kinds, use page[number], starting at 1.

    Parameters

    Returns Promise<ListSourcemapsResponse>

Generated using TypeDoc