@@ -115,7 +115,82 @@ Once you have .NET(C#) and `HttpClient` installed, follow these steps to execute
115
115
116
116
# # C# (RestSharp)
117
117
118
- TODO
118
+ Here are the detailed instructions for running the generated API Dash code in C# (using RestSharp) for macOS, Windows, and Linux:
119
+
120
+ # ## 1. Setting Up the C# Development Environment
121
+
122
+ # ### macOS and Windows
123
+ 1. ** Install .NET SDK**
124
+ - Visit the [official .NET download page](https://dotnet.microsoft.com/download).
125
+ - Download and install the latest .NET SDK for macOS.
126
+ 2. ** Verify Installation**
127
+ - Open the terminal and run the following command to verify the installation:
128
+ ` ` ` bash
129
+ dotnet --version
130
+ ` ` `
131
+
132
+ # ### Linux
133
+ 1. ** Install .NET SDK**
134
+ - Run the following commands based on your distribution:
135
+ - For Ubuntu/Debian-based systems:
136
+ ` ` ` bash
137
+ sudo apt update
138
+ sudo apt install dotnet-sdk-7.0
139
+ ` ` `
140
+ - For Fedora/CentOS-based systems:
141
+ ` ` ` bash
142
+ sudo dnf install dotnet-sdk-7.0
143
+ ` ` `
144
+ 2. ** Verify Installation**
145
+ - Open the terminal and run the following command to verify the installation:
146
+ ` ` ` bash
147
+ dotnet --version
148
+ ` ` `
149
+
150
+ # ## 2. Preparing a Project
151
+
152
+ # ### In Visual Studio
153
+
154
+ 1. ** Create a New Project**
155
+ - Open Visual Studio and select **Create a new project** .
156
+ - Choose the ** Console Application (.NET Core)** template and create the project.
157
+
158
+ 2. ** Install ` RestSharp` **
159
+ - Go to Tools > NuGet Package Manager > Manage NuGet Packages for Solution.
160
+ - Under the Browse tab, search for ` RestSharp` and install it.
161
+
162
+ # ### Using the CLI
163
+
164
+ 1. ** Create a Project**
165
+ ` ` ` bash
166
+ dotnet new console -n RestSharpExample
167
+ cd RestSharpExample
168
+ ` ` `
169
+
170
+ 2. ** Install the Package**
171
+ ` ` ` bash
172
+ dotnet add package RestSharp
173
+ ` ` `
174
+
175
+ # ## 3. Execute the generated code
176
+
177
+ Once you have .NET(C#) and ` RestSharp` installed, follow these steps to execute the generated code:
178
+
179
+ 1. Open a IDE/text editor (Visual Studio, VS Code or any other text editor).
180
+ 2. Copy the generated code from API Dash.
181
+ 3. Paste the code into your project like program.cs
182
+
183
+ # ### In Visual Studio
184
+
185
+ 1. Click the ** Start Debugging (F5)** button from the top menu to run the project.
186
+ 2. The output window will display the API response.
187
+
188
+ # ### Using the CLI
189
+
190
+ 1. Open the terminal at the project root directory and run the following command:
191
+ ` ` ` bash
192
+ dotnet run
193
+ ` ` `
119
194
120
195
# # Dart (http)
121
196
0 commit comments