You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+25-1Lines changed: 25 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,7 +25,7 @@ fields and additional request volumes see
25
25
26
26
[Click here to view the Java Spring SDK's API documentation](https://ipinfo.github.io/spring/).
27
27
28
-
⚠️ Note: This library does not currently support our newest free APIhttps://ipinfo.io/lite. If you’d like to use IPinfo Lite, you can call the [endpoint directly](https://ipinfo.io/developers/lite-api)using your preferred HTTP client. Developers are also welcome to contribute support for Lite by submitting a pull request.
28
+
The library also supports the Lite API, see the [Lite API section](#lite-api) for more info.
29
29
30
30
## Usage
31
31
@@ -174,6 +174,30 @@ The `AttributeStrategy` allows the middleware to know where to store the
174
174
Any exceptions such as `RateLimitedException` is passed through Spring's error
175
175
handling system.
176
176
177
+
### Lite API
178
+
179
+
The library gives the possibility to use the [Lite API](https://ipinfo.io/developers/lite-api) too, authentication with your token is still required.
180
+
181
+
The returned details are slightly different from the Core API.
182
+
183
+
To use the Lite API you must use the `IPinfoLiteSpring`, it works in the same way as the `IPinfoSpring` class.
// Set the IPStrategy. By default we use SimpleIPStrategy.
194
+
.ipStrategy(newSimpleIPStrategy())
195
+
// Set the AttributeStrategy. By default we use SessionAttributeStrategy.
196
+
.attributeStrategy(newSessionAttributeStrategy())
197
+
// Finally build it.
198
+
.build();
199
+
```
200
+
177
201
### Other Libraries
178
202
179
203
There are [official IPinfo client libraries](https://ipinfo.io/developers/libraries) available for many languages including PHP, Python, Go, Java, Ruby, and many popular frameworks such as Django, Rails, and Laravel. There are also many third-party libraries and integrations available for our API.
0 commit comments