> ## Documentation Index
> Fetch the complete documentation index at: https://docs.devin.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# EnterpriseCodeScansClient

## Constructor

```typescript
EnterpriseCodeScansClient(options: BaseClientOptions): CodeScansClient
```

### Parameters

**options** `BaseClientOptions` *required*

### Returns

`CodeScansClient`

## Methods

### getCodeScanMetrics()

```typescript
getCodeScanMetrics(request: GetCodeScanMetricsCodeScansRequest, requestOptions?: RequestOptions): HttpResponsePromise<CodeScanMetricsResponse>
```

Get aggregated code scan metrics for the enterprise account.

Returns scan, finding, and remediation-PR metrics for code scans created
within the specified time range, optionally filtered to specific
organizations.

```ts
await client.enterprise.codeScans.getCodeScanMetrics({
        time_before: 1,
        time_after: 1
    })
```

#### Parameters

**request** `GetCodeScanMetricsCodeScansRequest` *required*

**requestOptions** `RequestOptions`

Request-specific configuration.

#### Returns

`HttpResponsePromise<CodeScanMetricsResponse>`

### getCodeScanProfile()

```typescript
getCodeScanProfile(request: GetCodeScanProfileCodeScansRequest, requestOptions?: RequestOptions): HttpResponsePromise<CodeScanProfileDetailResponse>
```

Get a code scan profile by ID.

Returns the profile's metadata, visibility (org-owned or shared
account-wide), and all of its guidance fields. Returns `404` when the
profile does not exist or is not visible to the enterprise account.

```ts
await client.enterprise.codeScans.getCodeScanProfile({
        profile_id: "profile_id"
    })
```

#### Parameters

**request** `GetCodeScanProfileCodeScansRequest` *required*

**requestOptions** `RequestOptions`

Request-specific configuration.

#### Returns

`HttpResponsePromise<CodeScanProfileDetailResponse>`

### listCodeScanFindings()

```typescript
listCodeScanFindings(request?: ListCodeScanFindingsCodeScansRequest, requestOptions?: RequestOptions): Promise<Page<CodeScanFindingResponse, PaginatedResponseCodeScanFindingResponse>>
```

List code scan findings for the enterprise account.

Findings are returned newest first. Optionally filter by `org_ids`,
`scan_id`, `repo_name`, `severity`, and `status` (`severity` and
`status` accept multiple values); results are paginated with an opaque
cursor (`after` / `first`).

```ts
await client.enterprise.codeScans.listCodeScanFindings()
```

#### Parameters

**request** `ListCodeScanFindingsCodeScansRequest`

**requestOptions** `RequestOptions`

Request-specific configuration.

#### Returns

`Promise<Page<CodeScanFindingResponse, PaginatedResponseCodeScanFindingResponse>>`

### listCodeScanProfiles()

```typescript
listCodeScanProfiles(request?: ListCodeScanProfilesCodeScansRequest, requestOptions?: RequestOptions): Promise<Page<CodeScanProfileSummaryResponse, PaginatedResponseCodeScanProfileSummaryResponse>>
```

List code scan profiles for the enterprise account.

Returns profile summaries (without guidance) newest first, including both
org-owned and account-shared profiles. Optionally filter by `org_ids`;
results are paginated with an opaque cursor (`after` / `first`).

```ts
await client.enterprise.codeScans.listCodeScanProfiles()
```

#### Parameters

**request** `ListCodeScanProfilesCodeScansRequest`

**requestOptions** `RequestOptions`

Request-specific configuration.

#### Returns

`Promise<Page<CodeScanProfileSummaryResponse, PaginatedResponseCodeScanProfileSummaryResponse>>`

### listCodeScans()

```typescript
listCodeScans(request?: ListCodeScansCodeScansRequest, requestOptions?: RequestOptions): Promise<Page<CodeScanResponse, PaginatedResponseCodeScanResponse>>
```

List code scans for the enterprise account.

Scans are returned newest first. Optionally filter by `org_ids`,
`repo_name`, and creation time (`time_after` / `time_before`);
results are paginated with an opaque cursor (`after` / `first`).

```ts
await client.enterprise.codeScans.listCodeScans()
```

#### Parameters

**request** `ListCodeScansCodeScansRequest`

**requestOptions** `RequestOptions`

Request-specific configuration.

#### Returns

`Promise<Page<CodeScanResponse, PaginatedResponseCodeScanResponse>>`

### remediateCodeScanFinding()

```typescript
remediateCodeScanFinding(request: RemediateCodeScanFindingCodeScansRequest, requestOptions?: RequestOptions): HttpResponsePromise<RemediateFindingResponse>
```

Launch a Devin session to remediate a code scan finding.

The session analyzes the vulnerable code, implements a fix, and opens a
pull request. The session is attributed to the calling principal (the
service user or PAT that made the request). Returns `409` if the finding
already has a remediation session.

```ts
await client.enterprise.codeScans.remediateCodeScanFinding({
        org_id: "org-abc123def456",
        scan_id: "scan_id",
        finding_id: "finding_id"
    })
```

#### Parameters

**request** `RemediateCodeScanFindingCodeScansRequest` *required*

**requestOptions** `RequestOptions`

Request-specific configuration.

#### Returns

`HttpResponsePromise<RemediateFindingResponse>`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.