Skip to content

Java client library to execute operations on URLs using the Bitly API.

License

Notifications You must be signed in to change notification settings

opsmatters/bitly-java-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

53 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

opsmatters

Bitly Java API

Build Status Maven Central Javadocs

Java client library to execute operations on URLs using the Bitly V4 API.

The following Bitly APIs are currently supported:

Bitlinks

Custom Bitlinks

Groups

Organizations

Campaigns

Campaign Channels

Users

Webhooks

BSDs (Branded Short Domains)

OAuth Apps

Examples

A detailed set of examples of the usage of each of the APIs can be found on the API site.

Prerequisites

A Bitly account with an access token. The user needs to generate an Access Token to provide access via the Bitly V4 API. The Access Token is referenced in the documentation as the parameter "YOUR_ACCESS_TOKEN".

Installing

First clone the repository using:

>$ git clone https://github.com/opsmatters/bitly-java-api.git
>$ cd bitly-java-api

To compile the source code, run all tests, and generate all artefacts (including sources, javadoc, etc):

mvn package -Dbitly.access_token="<YOUR_ACCESS_TOKEN>"

Running the tests

To execute the unit tests:

mvn clean test -Dbitly.access_token="<YOUR_ACCESS_TOKEN>"

The following tests are included:

  • testBitlinksServices: Operations on bitlinks such as shorten and expand.

Deployment

The build artefacts are hosted in The Maven Central Repository.

Add the following dependency to include the artefact within your project:

<dependency>
  <groupId>com.opsmatters</groupId>
  <artifactId>bitly-java-api</artifactId>
  <version>1.0.2</version>
</dependency>

Built With

  • HttpComponents - RESTful Web Services in Java using HttpClient and HttpCore
  • Gson - Java serialization/deserialization library
  • Guava - An open-source set of common libraries for Java
  • Maven - Dependency Management
  • JUnit - Unit testing framework

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Versioning

This project use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the terms of the Apache license 2.0.

Copyright (c) 2020 OpsMatters

About

Java client library to execute operations on URLs using the Bitly API.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages