Upload source map

POST /api/apm/sourcemaps

Upload a source map for a specific service and version.

Headers

  • elastic-api-version string Required

    The version of the API to use

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

  • kbn-xsrf string Required

    A required header to protect against CSRF attacks

multipart/form-data

Body Required

  • bundle_filepath string Required

    The absolute path of the final bundle as used in the web application.

  • service_name string Required

    The name of the service that the service map should apply to.

  • service_version string Required

    The version of the service that the service map should apply to.

  • sourcemap string(binary) Required

    The source map. String or file upload. It must follow the source map revision 3 proposal.

Responses

  • 200 application/json

    Successful response

    Hide response attributes Show response attributes object
    • body string
    • 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

  • 403 application/json

    Forbidden 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

POST /api/apm/sourcemaps
curl \
 --request POST 'http://localhost:5601/api/apm/sourcemaps' \
 --header "Authorization: $API_KEY" \
 --header "Content-Type: multipart/form-data" \
 --header "elastic-api-version: 2023-10-31" \
 --header "kbn-xsrf: true" \
 --form "bundle_filepath=string" \
 --form "service_name=string" \
 --form "service_version=string" \
 --form "sourcemap=@file"