Skip to content

Commit cd3782c

Browse files
committed
Make readme consistent, include usage, testing
1 parent 9913b84 commit cd3782c

File tree

1 file changed

+38
-10
lines changed

1 file changed

+38
-10
lines changed

README.md

Lines changed: 38 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,49 @@
22

33
An API wrapper for the BlockScore API using Java.
44

5-
### System Requirements
6-
1. Java 1.7+
5+
### Requirements
6+
7+
- Java 1.7+
8+
9+
### Installation
10+
11+
#### Maven users
12+
13+
#### Gradle users
714

8-
## How to build
915
1. Clone this repository
1016
2. `./gradlew build`
1117
3. `./gradlew jar` (Builds the standard JAR) or `./gradlew fatJar` (Builds the plug and play jar)
1218

13-
## Usage
19+
#### Others
20+
21+
You can download our JAR files from here: https://github.com/BlockScore/blockscore-java/releases
22+
23+
### Usage
24+
25+
```java
26+
private static BlockscoreApiClient client = setupBlockscoreApiClient();
27+
28+
Address address = new Address("1 Infinite Loop", "Apt 6", "Cupertino", "CA", "95014", "US");
29+
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
30+
Date dateOfBirth = dateOfBirth = formatter.parse("1980-08-23");
31+
32+
Person.Builder builder = new Person.Builder(client);
33+
builder.setFirstName("John")
34+
.setMiddleName("Pearce")
35+
.setLastName("Doe")
36+
.setDocumentType("ssn")
37+
.setDocumentValue("0000")
38+
.setAddress(address)
39+
.setDateOfBirth(dateOfBirth);
40+
41+
builder.create();
42+
```
43+
44+
### Generating javadocs
1445

15-
## Generating javadocs
1646
1. `./gradlew docs`
1747

18-
## Dependencies
19-
1. Retrofit 1.6.1+
20-
2. Retrofit Converter-Jackson 1.6.1+
21-
3. OkHTTP 2.0+
22-
4. OkHTTP UrlConnection 2.0+
48+
### Testing
49+
50+
You must have gradle installed. Tests can be run by typing `./gradlew :test`.

0 commit comments

Comments
 (0)