Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import scala.collection.parallel.immutable.ParRange
import scala.util.{Failure, Properties, Success, Try}

object BitbucketClientBase {
val apiBaseUrl = "https://bitbucket.org/api/2.0"
val apiBaseUrl = "https://api.bitbucket.org/2.0"
}

abstract class BitbucketClientBase(val client: WSClient, credentials: Credentials) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package com.codacy.client.bitbucket.v2
import play.api.libs.functional.syntax._
import play.api.libs.json.{__, Reads}

case class AccessToken(access_token: String, refresh_token: String, expires_in: Int, scopes: String, token_type: String)
case class AccessToken(access_token: String, refresh_token: String, expires_in: Int, scope: String, token_type: String)

object AccessToken {

Expand All @@ -12,7 +12,7 @@ object AccessToken {
(__ \ "access_token").read[String] and
(__ \ "refresh_token").read[String] and
(__ \ "expires_in").read[Int] and
(__ \ "scopes").read[String] and
(__ \ "scope").read[String].orElse((__ \ "scopes").read[String]) and
(__ \ "token_type").read[String]
)(AccessToken.apply _)
// format: on
Expand Down