GET /api/apm/sourcemaps

Spaces method and path for this operation:

get /s/{space_id}/api/apm/sourcemaps

Refer to Spaces for more information.

Get an array of Fleet artifacts, including source map uploads. You must have read or all Kibana privileges for the APM and User Experience feature.

Headers

  • elastic-api-version string Required

    The version of the API to use

    Value is 2023-10-31. Default value is 2023-10-31.

Query parameters

  • page number

    Page number

  • perPage number

    Number of records per page

Responses

  • 200 application/json

    Successful response

    Hide response attribute Show response attribute object
    • artifacts array[object]

      Artifacts

      Hide artifacts attributes Show artifacts attributes object
      • body object
        Hide body attributes Show body attributes object
        • bundleFilepath string
        • serviceName string
        • serviceVersion string
        • sourceMap object
          Hide sourceMap attributes Show sourceMap attributes object
          • file string
          • mappings string
          • sourceRoot string
          • sources array[string]
          • sourcesContent array[string]
          • version number
      • compressionAlgorithm string

        Compression Algorithm

      • created string

        Created date

      • decodedSha256 string

        Decoded SHA-256

      • decodedSize number

        Decoded size

      • encodedSha256 string

        Encoded SHA-256

      • encodedSize number

        Encoded size

      • encryptionAlgorithm string

        Encryption Algorithm

      • id string

        Identifier

      • identifier string

        Identifier

      • packageName string

        Package name

      • relative_url string

        Relative URL

      • type string

        Type

  • 400 application/json

    Bad Request response

    Hide response attributes Show response attributes object
    • error string

      Error type

    • message string

      Error message

    • statusCode number

      Error status code

  • 401 application/json

    Unauthorized response

    Hide response attributes Show response attributes object
    • error string

      Error type

    • message string

      Error message

    • statusCode number

      Error status code

  • 500 application/json

    Internal Server Error response

    Hide response attributes Show response attributes object
    • error string

      Error type

    • message string

      Error message

    • statusCode number

      Error status code

  • 501 application/json

    Not Implemented response

    Hide response attributes Show response attributes object
    • error string

      Error type

    • message string

      Error message

    • statusCode number

      Error status code

GET /api/apm/sourcemaps
curl -X GET "http://localhost:5601/api/apm/sourcemaps" \
-H 'Content-Type: application/json' \
-H 'kbn-xsrf: true' \
-H 'Authorization: ApiKey ${YOUR_API_KEY}'
Response examples (200)
A successful response from `GET /api/apm/sourcemaps`.
{
  "artifacts": [
    {
      "body": {
        "bundleFilepath": "/test/e2e/general-usecase/bundle.js",
        "serviceName": "foo",
        "serviceVersion": "1.0.0",
        "sourceMap": {
          "file": "static/js/main.chunk.js",
          "mappings": "mapping",
          "sourceRoot": "",
          "sources": [
            "fleet-source-map-client/src/index.css",
            "fleet-source-map-client/src/App.js",
            "webpack:///./src/index.css?bb0a",
            "fleet-source-map-client/src/index.js",
            "fleet-source-map-client/src/reportWebVitals.js"
          ],
          "sourcesContent": [
            "content"
          ],
          "version": 3
        }
      },
      "compressionAlgorithm": "zlib",
      "created": "2021-07-09T20:47:44.812Z",
      "decodedSha256": "644fd5a997d1ddd90ee131ba18e2b3d03931d89dd1fe4599143c0b3264b3e456",
      "decodedSize": 441,
      "encodedSha256": "024c72749c3e3dd411b103f7040ae62633558608f480bce4b108cf5b2275bd24",
      "encodedSize": 237,
      "encryptionAlgorithm": "none",
      "id": "apm:foo-1.0.0-644fd5a997d1ddd90ee131ba18e2b3d03931d89dd1fe4599143c0b3264b3e456",
      "identifier": "foo-1.0.0",
      "packageName": "apm",
      "relative_url": "/api/fleet/artifacts/foo-1.0.0/644fd5a997d1ddd90ee131ba18e2b3d03931d89dd1fe4599143c0b3264b3e456",
      "type": "sourcemap"
    }
  ]
}
Response examples (400)
An example of a 400 Bad Request response, returned when the request payload or query parameters fail validation.
{
  "error": "Bad Request",
  "message": "[request body]: expected value of type [string] but got [undefined]",
  "statusCode": 400
}
Response examples (401)
An example of a 401 Unauthorized response, returned when the request is missing valid authentication credentials.
{
  "error": "Unauthorized",
  "message": "[security_exception]: missing authentication credentials for REST request",
  "statusCode": 401
}
Response examples (500)
An example of a 500 Internal Server Error response, returned when an unexpected error occurs while processing the request.
{
  "error": "Internal Server Error",
  "message": "An internal server error occurred. Check the Kibana server logs for details.",
  "statusCode": 500
}
Response examples (501)
An example of a 501 Not Implemented response, returned when the source map feature is not available on the current deployment.
{
  "error": "Not Implemented",
  "message": "Not Implemented",
  "statusCode": 501
}