Skip to content

Commit

Permalink
Release 0.0.0-alpha6
Browse files Browse the repository at this point in the history
  • Loading branch information
fern-api[bot] committed Oct 10, 2024
1 parent bcffb9f commit 75e8b0e
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 27 deletions.
10 changes: 5 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,14 @@ publishing {
publications {
maven(MavenPublication) {
groupId = 'dev.vapi'
artifactId = 'vapi-java-sdk'
version = '0.0.0-alpha3'
artifactId = 'server-sdk'
version = '0.0.0-alpha6'
from components.java
pom {
scm {
connection = 'scm:git:git://github.com/fern-demo/vapi-java-sdk.git'
developerConnection = 'scm:git:git://github.com/fern-demo/vapi-java-sdk.git'
url = 'https://github.com/fern-demo/vapi-java-sdk'
connection = 'scm:git:git://github.com/VapiAI/server-sdk-java.git'
developerConnection = 'scm:git:git://github.com/VapiAI/server-sdk-java.git'
url = 'https://github.com/VapiAI/server-sdk-java'
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/vapi/api/core/ClientOptions.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ private ClientOptions(
{
put("X-Fern-Language", "JAVA");
put("X-Fern-SDK-Name", "com.vapi.fern:api-sdk");
put("X-Fern-SDK-Version", "0.0.0-alpha3");
put("X-Fern-SDK-Version", "0.0.0-alpha6");
}
});
this.headerSuppliers = headerSuppliers;
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/vapi/api/types/PlayHtVoice.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
public final class PlayHtVoice {
private final Optional<Boolean> fillerInjectionEnabled;

private final PlayHtVoiceVoiceId voiceId;
private final PlayHtVoiceId voiceId;

private final Optional<Double> speed;

Expand All @@ -43,7 +43,7 @@ public final class PlayHtVoice {

private PlayHtVoice(
Optional<Boolean> fillerInjectionEnabled,
PlayHtVoiceVoiceId voiceId,
PlayHtVoiceId voiceId,
Optional<Double> speed,
Optional<Double> temperature,
Optional<PlayHtVoiceEmotion> emotion,
Expand Down Expand Up @@ -77,7 +77,7 @@ public Optional<Boolean> getFillerInjectionEnabled() {
* @return This is the provider-specific ID that will be used.
*/
@JsonProperty("voiceId")
public PlayHtVoiceVoiceId getVoiceId() {
public PlayHtVoiceId getVoiceId() {
return voiceId;
}

Expand Down Expand Up @@ -184,7 +184,7 @@ public static VoiceIdStage builder() {
}

public interface VoiceIdStage {
_FinalStage voiceId(@NotNull PlayHtVoiceVoiceId voiceId);
_FinalStage voiceId(@NotNull PlayHtVoiceId voiceId);

Builder from(PlayHtVoice other);
}
Expand Down Expand Up @@ -227,7 +227,7 @@ public interface _FinalStage {

@JsonIgnoreProperties(ignoreUnknown = true)
public static final class Builder implements VoiceIdStage, _FinalStage {
private PlayHtVoiceVoiceId voiceId;
private PlayHtVoiceId voiceId;

private Optional<ChunkPlan> chunkPlan = Optional.empty();

Expand Down Expand Up @@ -270,7 +270,7 @@ public Builder from(PlayHtVoice other) {
*/
@java.lang.Override
@JsonSetter("voiceId")
public _FinalStage voiceId(@NotNull PlayHtVoiceVoiceId voiceId) {
public _FinalStage voiceId(@NotNull PlayHtVoiceId voiceId) {
this.voiceId = Objects.requireNonNull(voiceId, "voiceId must not be null");
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@
import java.io.IOException;
import java.util.Objects;

@JsonDeserialize(using = PlayHtVoiceVoiceId.Deserializer.class)
public final class PlayHtVoiceVoiceId {
@JsonDeserialize(using = PlayHtVoiceId.Deserializer.class)
public final class PlayHtVoiceId {
private final Object value;

private final int type;

private PlayHtVoiceVoiceId(Object value, int type) {
private PlayHtVoiceId(Object value, int type) {
this.value = value;
this.type = type;
}
Expand All @@ -31,7 +31,7 @@ public Object get() {

public <T> T visit(Visitor<T> visitor) {
if (this.type == 0) {
return visitor.visit((PlayHtVoiceVoiceId) this.value);
return visitor.visit((PlayHtVoiceIdEnum) this.value);
} else if (this.type == 1) {
return visitor.visit((String) this.value);
}
Expand All @@ -41,10 +41,10 @@ public <T> T visit(Visitor<T> visitor) {
@java.lang.Override
public boolean equals(Object other) {
if (this == other) return true;
return other instanceof PlayHtVoiceVoiceId && equalTo((PlayHtVoiceVoiceId) other);
return other instanceof PlayHtVoiceId && equalTo((PlayHtVoiceId) other);
}

private boolean equalTo(PlayHtVoiceVoiceId other) {
private boolean equalTo(PlayHtVoiceId other) {
return value.equals(other.value);
}

Expand All @@ -58,30 +58,30 @@ public String toString() {
return this.value.toString();
}

public static PlayHtVoiceVoiceId of(PlayHtVoiceVoiceId value) {
return new PlayHtVoiceVoiceId(value, 0);
public static PlayHtVoiceId of(PlayHtVoiceIdEnum value) {
return new PlayHtVoiceId(value, 0);
}

public static PlayHtVoiceVoiceId of(String value) {
return new PlayHtVoiceVoiceId(value, 1);
public static PlayHtVoiceId of(String value) {
return new PlayHtVoiceId(value, 1);
}

public interface Visitor<T> {
T visit(PlayHtVoiceVoiceId value);
T visit(PlayHtVoiceIdEnum value);

T visit(String value);
}

static final class Deserializer extends StdDeserializer<PlayHtVoiceVoiceId> {
static final class Deserializer extends StdDeserializer<PlayHtVoiceId> {
Deserializer() {
super(PlayHtVoiceVoiceId.class);
super(PlayHtVoiceId.class);
}

@java.lang.Override
public PlayHtVoiceVoiceId deserialize(JsonParser p, DeserializationContext ctxt) throws IOException {
public PlayHtVoiceId deserialize(JsonParser p, DeserializationContext ctxt) throws IOException {
Object value = p.readValueAs(Object.class);
try {
return of(ObjectMappers.JSON_MAPPER.convertValue(value, PlayHtVoiceVoiceId.class));
return of(ObjectMappers.JSON_MAPPER.convertValue(value, PlayHtVoiceIdEnum.class));
} catch (IllegalArgumentException e) {
}
try {
Expand Down
40 changes: 40 additions & 0 deletions src/main/java/com/vapi/api/types/PlayHtVoiceIdEnum.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/**
* This file was auto-generated by Fern from our API Definition.
*/
package com.vapi.api.types;

import com.fasterxml.jackson.annotation.JsonValue;

public enum PlayHtVoiceIdEnum {
JENNIFER("jennifer"),

MELISSA("melissa"),

WILL("will"),

CHRIS("chris"),

MATT("matt"),

JACK("jack"),

RUBY("ruby"),

DAVIS("davis"),

DONNA("donna"),

MICHAEL("michael");

private final String value;

PlayHtVoiceIdEnum(String value) {
this.value = value;
}

@JsonValue
@java.lang.Override
public String toString() {
return this.value;
}
}

0 comments on commit 75e8b0e

Please sign in to comment.