Skip to content

Commit

Permalink
added web support
Browse files Browse the repository at this point in the history
  • Loading branch information
pangz-lab committed Apr 25, 2024
1 parent 92422f1 commit 75dfa2f
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 10 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## 1.2.2
2024/04/25 JST
- Added Web support
## 1.2.1
2023/08/26 JST
- README update to change the versioning
Expand Down
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!-- version 1.2.1 -->
![version](https://img.shields.io/badge/version-v1.2.1-blue)
<!-- version 1.2.2 -->
![version](https://img.shields.io/badge/version-v1.2.2-blue)
![coverage](https://img.shields.io/badge/coverage-100%25-success)
![sdk](https://img.shields.io/badge/sdk-v2.19.3-blue)
![license](https://img.shields.io/badge/license-BSD--3-blue)
Expand All @@ -12,7 +12,7 @@
<img src="https://img.shields.io/twitter/follow/Pangz55192569?style=social&logo=twitter" alt="follow on witter">
</a>

<p align="center">
<!-- <p align="center">
<img src="https://lh3.googleusercontent.com/fife/APg5EOY3h1MG5I3ny2d3X9NITN9GNuyx8uPlEu50W6GhYw-CsCPY7h_8DN1l9uYw8J7YjmUl9pDhuUhv6yrh5gv9jENoaWQcPebQ4NcsweTAtsFB2ehWWa9ETrSWCLoRTEVax27GsKGKVB6lLYNN1776Mytpv0RlNXgsnA-1eP30YQopud2cqf0YOTudo-heagG4oieBKBGr2A4ChIrQ5t0UglNYpmz8Q_F57k9mdq8hrBzuDmyUhdFI40tFZtg_vUKIZTY_vd2BIJmGkZZ3nuMMyZbOOMhgSTMxzlpb3dA23Gd2ymBGfNobQZOa4hBOpd_XxibFox5EOQOd9XpSbhdPt0EIAzXEb4qVsMJ4_NMW7OEdk0JQAjaAsFzZvVYL-uKFu-vzWSFg_GRWteDkUUYhv60V1H2zrmAfDdN10lE5Y9aiMbyc-62XSzaCtGBwSmmfP8iCdMP_RsJquvqWH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@ -21,14 +21,15 @@
<a href="https://www.coingecko.com/en/api">
<img src="https://pangz-lab.github.io/coupons/cgpangz2402-coupon-usage.png" height="500" />
</a>
</p>
</p> -->

# coingecko_client

## Coingecko API client for Dart
## CoinGecko API client for Dart
<br>
<p>
<img src="https://dart.dev/assets/shared/dart-logo-for-shares.png" height="150" />
<!-- <img src="https://dart.dev/assets/shared/dart-logo-for-shares.png" height="150" /> -->
<img src="https://files.readme.io/31ab3f6-small-CoinGecko_API_Documentation_-_SuperGecko.png" height="120" />
</p>

A simple and intuitive package for the [CoinGecko REST API Service](https://www.coingecko.com/en/api/documentation) ( v3 ).
Expand Down Expand Up @@ -93,7 +94,7 @@ Installation
Add the dependency to your Dart / Flutter project:<br>
( in `pubspec.yaml` file under the `dependencies`, add the following )
```yaml
coingecko_client: ^1.2.1
coingecko_client: ^1.2.2
```
<p></p>Go to <a href="https://pub.dev/packages/coingecko_client">pub.dev</a> for more details.</p>
Expand Down
3 changes: 1 addition & 2 deletions lib/src/domain/base_endpoint.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import 'dart:convert';
import 'dart:io';
import 'package:coingecko_client/src/models/exceptions/data_parsing_exception.dart';
import 'package:coingecko_client/src/models/exceptions/network_request_exception.dart';
import 'package:coingecko_client/src/models/exceptions/request_exception.dart';
Expand Down Expand Up @@ -70,7 +69,7 @@ class BaseEndpoint {
final query = urlComponent.length > 1 ? urlComponent.elementAt(1) : null;
final response = await httpRequestService
.sendGet(host, urlComponent.elementAt(0), query, headers: headers);
if (response.statusCode != HttpStatus.ok) {
if (response.statusCode != 200) {
throw NetworkRequestException.failedResponse(
response.statusCode, response);
}
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: coingecko_client
description: A simple and intuitive package for the CoinGecko REST API Service ( v3 )
version: 1.2.1
version: 1.2.2
repository: https://github.com/pangz-lab/coingecko_client
license: BSD 3-Clause

Expand Down

0 comments on commit 75dfa2f

Please sign in to comment.