|
51 | 51 |
|
52 | 52 | ## Dart (http)
|
53 | 53 |
|
54 |
| -TODO |
| 54 | +Here are the detailed instructions for running the generated API Dash code in **Dart (using `http`)** for macOS, Windows, and Linux: |
| 55 | + |
| 56 | +### **1. Install Dart** |
| 57 | + |
| 58 | +- Visit the official **[Dart Installation Guide](https://dart.dev/get-dart)** for step-by-step installation instructions for macOS, Windows, and Linux. |
| 59 | + |
| 60 | +### **2. Add the `http` Package** |
| 61 | + |
| 62 | +- Add the `http` package as a dependency under the `dependencies` section of the `pubspec.yaml` file: |
| 63 | + ```yaml |
| 64 | + dependencies: |
| 65 | + http: ^1.2.2 |
| 66 | + ``` |
| 67 | +- Run the following command to fetch the dependency: |
| 68 | + ```bash |
| 69 | + dart pub get |
| 70 | + ``` |
| 71 | + |
| 72 | +### **3. Run the Generated Code** |
| 73 | + |
| 74 | +#### **Using a Text Editor or IDE (e.g., Visual Studio Code):** |
| 75 | +1. Open a text editor or an IDE like Visual Studio Code. |
| 76 | +2. Create a new Dart file, such as `api_test.dart`. |
| 77 | +3. Copy the generated code from API Dash and paste it into this file. |
| 78 | +4. Save the file. |
| 79 | +5. Run the Dart file using the terminal or the IDE's built-in tools. |
| 80 | + |
| 81 | +#### **Using the Command Line:** |
| 82 | +1. Save the generated code to a Dart file, e.g., `api_test.dart`. |
| 83 | +2. Open a terminal and navigate to the directory containing the file. |
| 84 | +3. Run the Dart file with the following command: |
| 85 | + ```bash |
| 86 | + dart run api_test.dart |
| 87 | + ``` |
55 | 88 |
|
56 | 89 | ## Dart (dio)
|
57 | 90 |
|
58 |
| -TODO |
| 91 | +Here are the detailed instructions for running the generated API Dash code in **Dart (using `dio`)** for macOS, Windows, and Linux: |
| 92 | + |
| 93 | +### **1. Install Dart** |
| 94 | + |
| 95 | +- Visit the official **[Dart Installation Guide](https://dart.dev/get-dart)** for step-by-step installation instructions for macOS, Windows, and Linux. |
| 96 | + |
| 97 | +### **2. Add the `dio` Package** |
| 98 | + |
| 99 | +- Add the `dio` package as a dependency under the `dependencies` section of the `pubspec.yaml` file: |
| 100 | + ```yaml |
| 101 | + dependencies: |
| 102 | + dio: ^5.7.0 |
| 103 | + ``` |
| 104 | +- Run the following command to fetch the dependency: |
| 105 | + ```bash |
| 106 | + dart pub get |
| 107 | + ``` |
| 108 | + |
| 109 | +### **3. Run the Generated Code** |
| 110 | + |
| 111 | +#### **Using a Text Editor or IDE (e.g., Visual Studio Code):** |
| 112 | +1. Open a text editor or an IDE like Visual Studio Code. |
| 113 | +2. Create a new Dart file, such as `api_test.dart`. |
| 114 | +3. Copy the generated code from API Dash and paste it into this file. |
| 115 | +4. Save the file. |
| 116 | +5. Run the Dart file using the terminal or the IDE's built-in tools. |
| 117 | + |
| 118 | +#### **Using the Command Line:** |
| 119 | +1. Save the generated code to a Dart file, e.g., `api_test.dart`. |
| 120 | +2. Open a terminal and navigate to the directory containing the file. |
| 121 | +3. Run the Dart file with the following command: |
| 122 | + ```bash |
| 123 | + dart run api_test.dart |
| 124 | + ``` |
59 | 125 |
|
60 | 126 | ## Go (net/http)
|
61 | 127 |
|
|
0 commit comments