---
title: "Update Package Manager Auth Config"
method: PATCH
path: "/api/agent/deployments/{deploymentId}/packagemanagerauthconfigs/{packageManagerConfigId}"
tags: ["SmsPackageManagerConfigService"]
---

# Update Package Manager Auth Config

`PATCH /api/agent/deployments/{deploymentId}/packagemanagerauthconfigs/{packageManagerConfigId}`

Update an existing package manager authentication configuration.

## Path parameters

- `deploymentId` integer, required — The unique identifier for the deployment.
- `packageManagerConfigId` integer, required — The unique identifier for the package manager configuration to update.

## Request body

- ProtosSmsV2UpdatePackageManagerAuthCredentialsRequest
  - `deploymentId` integer — The unique identifier for the deployment.
  - `packageManagerConfigId` integer — The unique identifier for the package manager configuration to update.
  - `packageManagerConfigForInsert` ProtosSmsV2PackageManagerConfigForInsert — Should not be used except for when creating new configs
    - `config` ProtosSmsV2PackageManagerConfig — Represents properties of the PackageManagerConfig model without the credentials
      - `id` integer — The unique identifier for the package manager configuration.
      - `name` string — A human-readable name for the package manager configuration.
      - `url` string — The URL of the package manager repository.
      - `requiresAuth` boolean — Whether this package manager repository requires authentication.
      - `ecosystem` 'no_package_manager' | 'npm' | 'pypi' | 'gomod' | 'cargo' | 'maven' | 'gem' | 'composer' | 'nuget' | 'pub' | 'swiftpm' | 'hex' | 'cocoapods' | 'mix' | 'opam', enum — The package manager ecosystem (e.g., Maven, PyPI). | value | description | |-------|---------------| | no_package_manager | | | npm | | | pypi | | | gomod | | | cargo | | | maven | | | gem | | | composer | | | nuget | | | pub | | | swiftpm | | | hex | | | cocoapods | | | mix | | | opam | |
      - `deploymentId` integer — The unique identifier for the deployment this configuration belongs to.
      - `useNetworkBroker` boolean — Whether or not requests to this package registry should be routed through the network broker.
      - `additionalConfig` ProtosSmsV2AdditionalConfig
        - `maven` ProtosSmsV2MavenConfig
          - `repositoryType` 'MAVEN_REPOSITORY_TYPE_RELEASE' | 'MAVEN_REPOSITORY_TYPE_SNAPSHOT' | 'MAVEN_REPOSITORY_TYPE_BOTH', enum — Specifies whether this Maven repository serves release artifacts, snapshot artifacts, or both. | value | description | |-------|---------------| | MAVEN_REPOSITORY_TYPE_RELEASE | | | MAVEN_REPOSITORY_TYPE_SNAPSHOT | | | MAVEN_REPOSITORY_TYPE_BOTH | |
        - `pypi` ProtosSmsV2PypiConfig
        - `npm` ProtosSmsV2NpmConfig
          - `scope` string — npm scope this registry serves (e.g. @my-org). Optional; omit for a default registry.
    - `maven` ProtosSmsV2MavenCredentials
      - `username` string — Username for Maven repository authentication.
      - `password` string — Password for Maven repository authentication.
    - `pypi` ProtosSmsV2PypiCredentials
      - `username` string — Username for PyPI repository authentication.
      - `password` string — Password for PyPI repository authentication.
    - `codeArtifact` ProtosSmsV2CodeArtifactCredentials
      - `assumeRoleArn` string — The ARN of the IAM role to assume for CodeArtifact access.
    - `npm` ProtosSmsV2NpmCredentials
      - `token` string — npm registry auth token.
      - `basicAuth` ProtosSmsV2NpmCredentialsBasicAuth
        - `username` string — Username for basic-auth npm registries.
        - `password` string — Password for basic-auth npm registries.

## Response `200`

OK

- ProtosSmsV2UpdatePackageManagerAuthCredentialsResponse
  - `packageManagerConfig` ProtosSmsV2PackageManagerConfig — Represents properties of the PackageManagerConfig model without the credentials
    - `id` integer — The unique identifier for the package manager configuration.
    - `name` string — A human-readable name for the package manager configuration.
    - `url` string — The URL of the package manager repository.
    - `requiresAuth` boolean — Whether this package manager repository requires authentication.
    - `ecosystem` 'no_package_manager' | 'npm' | 'pypi' | 'gomod' | 'cargo' | 'maven' | 'gem' | 'composer' | 'nuget' | 'pub' | 'swiftpm' | 'hex' | 'cocoapods' | 'mix' | 'opam', enum — The package manager ecosystem (e.g., Maven, PyPI). | value | description | |-------|---------------| | no_package_manager | | | npm | | | pypi | | | gomod | | | cargo | | | maven | | | gem | | | composer | | | nuget | | | pub | | | swiftpm | | | hex | | | cocoapods | | | mix | | | opam | |
    - `deploymentId` integer — The unique identifier for the deployment this configuration belongs to.
    - `useNetworkBroker` boolean — Whether or not requests to this package registry should be routed through the network broker.
    - `additionalConfig` ProtosSmsV2AdditionalConfig
      - `maven` ProtosSmsV2MavenConfig
        - `repositoryType` 'MAVEN_REPOSITORY_TYPE_RELEASE' | 'MAVEN_REPOSITORY_TYPE_SNAPSHOT' | 'MAVEN_REPOSITORY_TYPE_BOTH', enum — Specifies whether this Maven repository serves release artifacts, snapshot artifacts, or both. | value | description | |-------|---------------| | MAVEN_REPOSITORY_TYPE_RELEASE | | | MAVEN_REPOSITORY_TYPE_SNAPSHOT | | | MAVEN_REPOSITORY_TYPE_BOTH | |
      - `pypi` ProtosSmsV2PypiConfig
      - `npm` ProtosSmsV2NpmConfig
        - `scope` string — npm scope this registry serves (e.g. @my-org). Optional; omit for a default registry.

---

[API](https://skmtc.net/semgrep/apis/semgrep-web-app.md) · [All operations](https://skmtc.net/semgrep/apis/semgrep-web-app/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/semgrep/semgrep-web-app/revisions/6483eeecd582/schema)
