--- sidebar_label: C# title: Connect with C# Connector description: Connect to TDengine cloud service using C# connector --- import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; ## Create Project ```bash dotnet new console -o example ``` ## Add C# TDengine Driver class lib ```bash cd example dotnet add package TDengine.Connector ``` ## Config Run this command in your terminal to save TDengine cloud token as variables: ```bash export TDENGINE_CLOUD_DSN="" ``` ```bash set TDENGINE_CLOUD_DSN="" ``` ```powershell $env:TDENGINE_CLOUD_DSN="" ``` :::note Replace with real TDengine cloud DSN. To obtain the real value, please log in [TDengine Cloud](https://cloud.tdengine.com) and click "Connector" and then select "C#". ::: ## Connect ``` XML Exe net5.0 enable ``` ```C# //{{#include docs/examples/csharp/cloud-example/Connect.cs}} ```