Skip to content

Commit d1f5a67

Browse files
Added the User-Agent in the header
1 parent f56d9a4 commit d1f5a67

File tree

7 files changed

+16
-9
lines changed

7 files changed

+16
-9
lines changed

.vscode/settings.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"java.configuration.updateBuildConfiguration": "interactive"
3+
}

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# 1.0.4
2+
3+
- Added the User-Agent in the header
4+
15
# 1.0.3
26

37
- Added a new endpoint and example to credit card payment retry

README-en.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ For more informations about [parameters](http://dev.sejaefi.com.br) and [values]
1616
* Java >= 7.0
1717

1818
## Tested with
19-
> java 7.0, 8.0, 13.0 and 20.0
19+
> java 7.0, 8.0, 13.0 and 18.0
2020
2121
## Installation
2222
**Via gradle:**
2323

2424
```gradle
25-
implementation 'br.com.efipay.efisdk:sdk-java-apis-efi:1.0.0'
25+
implementation 'br.com.efipay.efisdk:sdk-java-apis-efi:1.0.4'
2626
```
2727

2828
**Via maven:**
@@ -31,7 +31,7 @@ implementation 'br.com.efipay.efisdk:sdk-java-apis-efi:1.0.0'
3131
<dependency>
3232
    <groupId>br.com.efipay.efisdk</groupId>
3333
<artifactId>sdk-java-apis-efi</artifactId>
34-
<version>1.0.0</version>
34+
<version>1.0.4</version>
3535
</dependency>
3636
```
3737

pom.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<modelVersion>4.0.0</modelVersion>
44
<groupId>br.com.efipay.efisdk</groupId>
55
<artifactId>sdk-java-apis-efi</artifactId>
6-
<version>1.0.3</version>
6+
<version>1.0.4</version>
77

88
<name>SDK JAVA APIS EFI</name>
99
<description>Java SDK for integrating with Efí API</description>
@@ -110,7 +110,7 @@
110110
<plugin>
111111
<groupId>org.sonatype.plugins</groupId>
112112
<artifactId>nexus-staging-maven-plugin</artifactId>
113-
<version>1.6.7</version>
113+
<version>1.6.13</version>
114114
<extensions>true</extensions>
115115
<configuration>
116116
<serverId>ossrh</serverId>
@@ -202,8 +202,8 @@
202202
<plugin>
203203
<groupId>org.apache.maven.plugins</groupId>
204204
<artifactId>maven-javadoc-plugin</artifactId>
205-
<version>2.9.1</version>
206-
<configuration>
205+
<version>3.3.0</version>
206+
<configuration combine.self="override">
207207
<source>8</source>
208208
<detectJavaApiLink>false</detectJavaApiLink>
209209
</configuration>

src/main/java/br/com/efi/efisdk/Config.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
*
1212
*/
1313
public class Config {
14-
private final static String version = "1.0.3";
14+
private final static String version = "1.0.4";
1515
private JSONObject conf = new JSONObject();
1616
private JSONObject endpoints = new JSONObject();
1717
private JSONObject urls = new JSONObject();

src/main/java/br/com/efi/efisdk/Endpoints.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ public Endpoints(JSONObject options) throws Exception {
3939
}
4040

4141
/**
42-
* Constructor Map<String, Object>
4342
*
4443
* @param options Map com as definiçõess da API
4544
* @throws Exception

src/main/java/br/com/efi/efisdk/Request.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ public Request(String method, HttpURLConnection conn) throws IOException {
2828
this.client = conn;
2929
this.client.setRequestProperty("Content-Type", "application/json");
3030
this.client.setRequestProperty("charset", "UTF-8");
31+
this.client.setRequestProperty("User-Agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36");
3132
this.client.setRequestProperty("api-sdk", "efi-java-" + Config.getVersion());
3233

3334
if (method.toUpperCase().equals("PATCH")) {

0 commit comments

Comments
 (0)