reactive-github-client

Reactive GitHub API Client

License

License

Categories

Categories

Github Development Tools Version Controls React User Interface Web Frameworks CLI
GroupId

GroupId

am.ik.github
ArtifactId

ArtifactId

reactive-github-client
Last Version

Last Version

0.0.4
Release Date

Release Date

Type

Type

jar
Description

Description

reactive-github-client
Reactive GitHub API Client
Project URL

Project URL

https://github.com/making/reactive-github-client
Source Code Management

Source Code Management

https://github.com/making/reactive-github-client

Download reactive-github-client

How to add to project

<!-- https://jarcasting.com/artifacts/am.ik.github/reactive-github-client/ -->
<dependency>
    <groupId>am.ik.github</groupId>
    <artifactId>reactive-github-client</artifactId>
    <version>0.0.4</version>
</dependency>
// https://jarcasting.com/artifacts/am.ik.github/reactive-github-client/
implementation 'am.ik.github:reactive-github-client:0.0.4'
// https://jarcasting.com/artifacts/am.ik.github/reactive-github-client/
implementation ("am.ik.github:reactive-github-client:0.0.4")
'am.ik.github:reactive-github-client:jar:0.0.4'
<dependency org="am.ik.github" name="reactive-github-client" rev="0.0.4">
  <artifact name="reactive-github-client" type="jar" />
</dependency>
@Grapes(
@Grab(group='am.ik.github', module='reactive-github-client', version='0.0.4')
)
libraryDependencies += "am.ik.github" % "reactive-github-client" % "0.0.4"
[am.ik.github/reactive-github-client "0.0.4"]

Dependencies

compile (6)

Group / Artifact Type Version
org.springframework : spring-webflux jar 5.0.0.RELEASE
com.fasterxml.jackson.core : jackson-core jar 2.9.1
com.fasterxml.jackson.core : jackson-databind jar 2.9.1
com.fasterxml.jackson.core : jackson-annotations jar 2.9.1
com.fasterxml.jackson.datatype : jackson-datatype-jsr310 jar 2.9.1
io.projectreactor.ipc : reactor-netty jar

test (3)

Group / Artifact Type Version
junit : junit jar 4.12
io.projectreactor : reactor-test jar
org.assertj : assertj-core jar 3.8.0

Project Modules

There are no modules declared in this project.

Reactive GitHub API Client

GitHub API Client that uses Reactor's Flux/Mono and Spring 5's WebClient.

Supported API

Usage

<dependency>
    <groupId>am.ik.github</groupId>
    <artifactId>reactive-github-client</artifactId>
    <version>${reactive-github-client.version}</version>
</dependency>
GitHubClient client = new GitHubClient(WebClient.builder(), new AccessToken("xxxxxx"));

Contents API

Get a file

ContentsApi.File file = client.file("making", "reactive-github-client", "pom.xml");
Mono<ContentsResponse.File> pom = file.get();

Create a file

ContentsApi.File file = client.file("making", "reactive-github-client", "foo.txt");
Mono<ContentsResponse.Put> created = file.create(ContentsRequest.Builder
                .fromPlainText("Hello World!")
                .toCreate("Create foo.txt"));

Update a file

ContentsApi.File file = client.file("making", "reactive-github-client", "foo.txt");
Mono<ContentsResponse.Put> updated = file.update(ContentsRequest.Builder
                .fromPlainText("Hello World!!!!!")
                .toUpdate("Update foo.txt", "sha of foo.txt"));

Delete a file

ContentsApi.File file = client.file("making", "reactive-github-client", "foo.txt");
Mono<ContentsResponse.Delete> deleted = file.delete(ContentsRequest.Builder
                .noContent()
                .toDelete("Delete foo.txt", "sha of foo.txt"));

Versions

Version
0.0.4
0.0.3
0.0.2
0.0.1