-
-
Notifications
You must be signed in to change notification settings - Fork 7.4k
Closed
Closed
Copy link
Labels
Description
Example generated code with separateErrorChannel=true (code does compile):
def appRoleDeleteBindSecretId(roleName: String, approleMountPath: String): sttp.client4.Request[Either[ResponseException[String], Unit]] =
val roleNamePathParam = PathSerializable.serialize("role_name", roleName, PathStyleFormat.SIMPLE, false)
val approleMountPathPathParam = PathSerializable.serialize("approle_mount_path", approleMountPath, PathStyleFormat.SIMPLE, false)
val requestURL =
uri"$baseUrl/auth/${approleMountPathPathParam}/role/${roleNamePathParam}/bind-secret-id"
basicRequest
.method(Method.DELETE, requestURL)
.contentType("application/json")
.response(asString.mapWithMetadata(ResponseAs.deserializeRightWithError(_ => Right(()))))Example generated code with separateErrorChannel=false (code does not compile):
def appRoleDeleteBindSecretId(roleName: String, approleMountPath: String): sttp.client4.Request[Unit] =
val roleNamePathParam = PathSerializable.serialize("role_name", roleName, PathStyleFormat.SIMPLE, false)
val approleMountPathPathParam = PathSerializable.serialize("approle_mount_path", approleMountPath, PathStyleFormat.SIMPLE, false)
val requestURL =
uri"$baseUrl/auth/${approleMountPathPathParam}/role/${roleNamePathParam}/bind-secret-id"
basicRequest
.method(Method.DELETE, requestURL)
.contentType("application/json")
.response(asString.mapWithMetadata(ResponseAs.deserializeRightWithError(_ => Right(()))).getRight)
value getRight is not a member of sttp.client4.ResponseAs[Either[sttp.client4.ResponseException[String], Unit]] - did you mean sttp.client4.ResponseAs[Either[sttp.client4.ResponseException[String], Unit]].mapRight?
.response(asString.mapWithMetadata(ResponseAs.deserializeRightWithError(_ => Right(()))).getRight)Reactions are currently unavailable