Skip to content

Commit 81ca3eb

Browse files
committed
Remove all references to Secret and ApiKey #44
1 parent 2fbcedd commit 81ca3eb

File tree

11 files changed

+15
-15
lines changed

11 files changed

+15
-15
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ And many others files manipulations.
88
In just few minutes you can integrate it into your application and use it easily.
99

1010
The ConvertAPI-Java library makes it easier to use the Convert API from your Java 8 projects without having to build your own API calls.
11-
You can get your free API credentials at https://www.convertapi.com/a
11+
You can get your free API token at https://www.convertapi.com/a/authentication
1212

1313
## Installation
1414

@@ -27,10 +27,10 @@ Add the following dependency to your pom.xml:
2727

2828
### Configuration
2929

30-
You can get your credentials at https://www.convertapi.com/a
30+
You can get your token at https://www.convertapi.com/a/authentication
3131

3232
```java
33-
Config.setDefaultApiCredentials("your-api-credentials");
33+
Config.setDefaultApiCredentials("api-token");
3434
```
3535

3636
### File conversion
@@ -111,13 +111,13 @@ import com.convertapi.ConvertApi;
111111

112112
public class SimpleConversion {
113113
public static void main(String[] args) {
114-
ConvertApi.convert("source.docx", "result.pdf", "your-api-credentials");
114+
ConvertApi.convert("source.docx", "result.pdf", "api-token");
115115
}
116116
}
117117
```
118118

119119
This is the bare-minimum to convert a file using the ConvertAPI client, but you can do a great deal more with the ConvertAPI Java library.
120-
Take special note that you should replace `your-api-credentials` with the credentials you obtained in item two of the pre-requisites.
120+
Take special note that you should replace `api-token` with the token you obtained in item two of the pre-requisites.
121121

122122
### Issues & Comments
123123
Please leave all comments, bugs, requests, and issues on the Issues page. We'll respond to your request ASAP!

examples/src/main/java/com/convertapi/examples/Advanced.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
public class Advanced {
2222

2323
public static void main(String[] args) throws ExecutionException, InterruptedException {
24-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
24+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2525

2626
// Advanced HTTP client setup
2727
Config.setDefaultHttpBuilder(builder -> {

examples/src/main/java/com/convertapi/examples/ConversionChaining.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
public class ConversionChaining {
2222

2323
public static void main(String[] args) throws IOException, ExecutionException, InterruptedException {
24-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
24+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2525

2626
System.out.println("Converting PDF to JPG and compressing result files with ZIP");
2727
CompletableFuture<ConversionResult> jpgResult = ConvertApi.convert("docx", "jpg", new Param("file", Paths.get("files/test.docx")));

examples/src/main/java/com/convertapi/examples/ConvertRemoteFile.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
public class ConvertRemoteFile {
2121

2222
public static void main(String[] args) throws ExecutionException, InterruptedException {
23-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
23+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2424

2525
System.out.println("Converting remote PPTX to PDF");
2626
CompletableFuture<ConversionResult> result = ConvertApi.convert("pptx", "pdf",

examples/src/main/java/com/convertapi/examples/ConvertStream.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
public class ConvertStream {
2323

2424
public static void main(String[] args) throws ExecutionException, InterruptedException, IOException {
25-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
25+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2626

2727
// Creating file data stream
2828
InputStream stream = Files.newInputStream(new File("src/main/resources/test.docx").toPath());

examples/src/main/java/com/convertapi/examples/ConvertWebToPdf.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
public class ConvertWebToPdf {
2121

2222
public static void main(String[] args) throws ExecutionException, InterruptedException {
23-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
23+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2424

2525
System.out.println("Converting WEB to PDF");
2626
CompletableFuture<ConversionResult> result = ConvertApi.convert("web", "pdf",

examples/src/main/java/com/convertapi/examples/ConvertWordToPdfAndPng.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
public class ConvertWordToPdfAndPng {
2424

2525
public static void main(String[] args) throws IOException, ExecutionException, InterruptedException {
26-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
26+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2727
Path tempDir = Paths.get(System.getProperty("java.io.tmpdir"));
2828

2929
System.out.println("Converting DOCX to PDF and JPG in parallel");

examples/src/main/java/com/convertapi/examples/CreatePdfThumbnail.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
public class CreatePdfThumbnail {
2222

2323
public static void main(String[] args) throws IOException, ExecutionException, InterruptedException {
24-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
24+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2525
Path tempDir = Paths.get(System.getProperty("java.io.tmpdir"));
2626

2727
System.out.println("Creating PDF thumbnail");

examples/src/main/java/com/convertapi/examples/SimpleConversion.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
public class SimpleConversion {
1212

1313
public static void main(String[] args) {
14-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
14+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
1515
String resourcePath = "files/test.docx";
1616
String tmpDir = System.getProperty("java.io.tmpdir") + "/";
1717

examples/src/main/java/com/convertapi/examples/SplitAndMergePdf.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
public class SplitAndMergePdf {
2222

2323
public static void main(String[] args) throws IOException, ExecutionException, InterruptedException {
24-
Config.setDefaultApiCredentials(getenv("CONVERTAPI_CREDENTIALS")); //Get your api credentials at https://www.convertapi.com/a
24+
Config.setDefaultApiCredentials(getenv("API_TOKEN")); // Get your api token at https://www.convertapi.com/a/authentication
2525
Path tempDir = Paths.get(System.getProperty("java.io.tmpdir"));
2626

2727
System.out.println("Creating PDF with the first and the last pages");

0 commit comments

Comments
 (0)