Files
Maria Kiss Vajdova d662cb4399 No public description
PiperOrigin-RevId: 995078097
2026-10-07 13:55:36 +00:00
..
2026-10-07 13:55:36 +00:00
2026-05-20 14:40:36 +00:00
2025-07-01 09:31:15 +00:00
2025-07-01 09:31:15 +00:00
2026-07-10 12:16:23 +00:00

Google Merchant API C#/.NET Samples

This is a set of simple samples written in C#/.NET, which provide a minimal example of Google Merchant API integration within a command line application.


Prerequisites for Running

1. Development Environment

You will need a C# development environment such as:

2. Setup Authentication and Sample Configuration

If you have not already done so, please read the top-level README.md to discover how to set up both authentication and the common sample configuration.


Running the Samples

All commands should be run from the dotnet/ directory.

cd dotnet/

1. Restore NuGet Packages

Restore the dependencies for the projects (for more details, see .NET Package Restore):

dotnet restore

2. Developer Registration

Before calling any v1 Merchant API method, you must register the GCP project used to call the APIs. You only need to do this once.

dotnet run --project examples/accounts/developerRegistration/v1/RegisterGcpSample.csproj --framework netcoreapp8.0

For more information, see Register as a developer.

3. Run a Sample

To run a specific sample project, use dotnet run --project pointing to the .csproj file. For example, to list your products, run:

dotnet run --project examples/products/v1/ListProductsSample.csproj --framework netcoreapp8.0

Examine your shell output, be inspired, and start working on an amazing new app!