public sealed class Artifacts.Types.NpmPackage : IMessage<Artifacts.Types.NpmPackage>, IEquatable<Artifacts.Types.NpmPackage>, IDeepCloneable<Artifacts.Types.NpmPackage>, IBufferMessage, IMessage
Reference documentation and code samples for the Cloud Build v1 API class Artifacts.Types.NpmPackage.
Npm package to upload to Artifact Registry upon successful completion
of all build steps.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-19 UTC."],[[["\u003cp\u003eThe latest version of the \u003ccode\u003eNpmPackage\u003c/code\u003e class in the Cloud Build v1 API is 2.15.0, with multiple historical versions available, ranging from 1.0.0 to 2.14.0.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eArtifacts.Types.NpmPackage\u003c/code\u003e is a class that represents an Npm package intended for upload to Artifact Registry following the successful completion of all build steps.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eNpmPackage\u003c/code\u003e class has properties \u003ccode\u003ePackagePath\u003c/code\u003e, which specifies the location of the package.json, and \u003ccode\u003eRepository\u003c/code\u003e, which indicates the Artifact Registry repository path.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eNpmPackage\u003c/code\u003e class inherits from \u003ccode\u003eobject\u003c/code\u003e and implements interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe class also has 2 constructors available, one default and one that accepts another \u003ccode\u003eNpmPackage\u003c/code\u003e object as a parameter.\u003c/p\u003e\n"]]],[],null,["# Cloud Build v1 API - Class Artifacts.Types.NpmPackage (2.16.0)\n\nVersion latestkeyboard_arrow_down\n\n- [2.16.0 (latest)](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.15.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.15.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.14.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.14.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.13.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.13.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.12.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.12.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.11.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.11.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.10.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.10.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.9.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.9.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.8.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.8.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.7.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.7.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.6.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.6.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.5.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.5.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.4.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.4.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.3.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.3.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.2.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.2.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.1.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.1.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [2.0.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/2.0.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [1.4.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/1.4.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [1.3.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/1.3.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [1.2.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/1.2.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [1.1.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/1.1.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage)\n- [1.0.0](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/1.0.0/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage) \n\n public sealed class Artifacts.Types.NpmPackage : IMessage\u003cArtifacts.Types.NpmPackage\u003e, IEquatable\u003cArtifacts.Types.NpmPackage\u003e, IDeepCloneable\u003cArtifacts.Types.NpmPackage\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Cloud Build v1 API class Artifacts.Types.NpmPackage.\n\nNpm package to upload to Artifact Registry upon successful completion\nof all build steps. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e Artifacts.Types.NpmPackage \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[Artifacts](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts)[Types](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts.Types)[NpmPackage](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[Artifacts](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts)[Types](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts.Types)[NpmPackage](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[Artifacts](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts)[Types](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts.Types)[NpmPackage](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1.Artifacts.Types.NpmPackage), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.CloudBuild.V1](/dotnet/docs/reference/Google.Cloud.CloudBuild.V1/latest/Google.Cloud.CloudBuild.V1)\n\nAssembly\n--------\n\nGoogle.Cloud.CloudBuild.V1.dll\n\nConstructors\n------------\n\n### NpmPackage()\n\n public NpmPackage()\n\n### NpmPackage(NpmPackage)\n\n public NpmPackage(Artifacts.Types.NpmPackage other)\n\nProperties\n----------\n\n### PackagePath\n\n public string PackagePath { get; set; }\n\nPath to the package.json.\ne.g. workspace/path/to/package\n\n### Repository\n\n public string Repository { get; set; }\n\nArtifact Registry repository, in the form\n\"https://$REGION-npm.pkg.dev/$PROJECT/$REPOSITORY\"\n\nNpm package in the workspace specified by path will be zipped and\nuploaded to Artifact Registry with this location as a prefix."]]