---
type: api
title: Get source maps
description: **Spaces method and path for this operation:**
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v8/operation/operation-getsourcemaps
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v8/operation/operation-getsourcemaps
products:
  - Kibana
---

# Get source maps

- Server: `https://{kibana_url}`

## Paths

- `GET` `/api/apm/sourcemaps`
- `GET` `/s/{space_id}/api/apm/sourcemaps`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v8/authentication#apikeyauth)
- [Basic auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v8/authentication#basicauth)

## Description

Refer to [Spaces](https://www.elastic.co/docs/deploy-manage/manage-spaces) for more information.

Returns an array of Fleet artifacts, including source map uploads.

## Query String Parameters

- `page` (number)
  Page number
- `perPage` (number)
  Number of records per page

## Responses

#### `200`

Successful response

`application/json`

- `artifacts` ([] object)
  Artifacts
  - `body` (object)
    - `bundleFilepath` (string)
    - `serviceName` (string)
    - `serviceVersion` (string)
    - `sourceMap` (object)
      - `file` (string)
      - `mappings` (string)
      - `sourceRoot` (string)
      - `sources` ([] string)
      - `sourcesContent` ([] 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`

Bad Request response

`application/json`

- `error` (string)
  Error type
- `message` (string)
  Error message
- `statusCode` (number)
  Error status code
#### `401`

Unauthorized response

`application/json`

- `error` (string)
  Error type
- `message` (string)
  Error message
- `statusCode` (number)
  Error status code
#### `500`

Internal Server Error response

`application/json`

- `error` (string)
  Error type
- `message` (string)
  Error message
- `statusCode` (number)
  Error status code
#### `501`

Not Implemented response

`application/json`

- `error` (string)
  Error type
- `message` (string)
  Error message
- `statusCode` (number)
  Error status code
## Code Examples

#### Console

```console
GET /api/apm/sourcemaps
```

#### curl

```curl
curl -X GET "https://{kibana_url}/api/apm/sourcemaps" \
  -H "elastic-api-version: string"
```

