https://github.com/codacy/codacy-api-scala
Scala wrapper for the Codacy API
https://github.com/codacy/codacy-api-scala
Last synced: 6 months ago
JSON representation
Scala wrapper for the Codacy API
- Host: GitHub
- URL: https://github.com/codacy/codacy-api-scala
- Owner: codacy
- License: mit
- Created: 2015-04-21T09:46:07.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2025-06-16T11:28:01.000Z (7 months ago)
- Last Synced: 2025-07-10T07:40:53.848Z (7 months ago)
- Language: Scala
- Homepage: https://www.codacy.com
- Size: 155 KB
- Stars: 6
- Watchers: 19
- Forks: 5
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# Codacy API Scala Client
Scala wrapper for the Codacy API.
[](https://www.codacy.com/gh/codacy/codacy-api-scala?utm_source=github.com&utm_medium=referral&utm_content=codacy/codacy-api-scala&utm_campaign=Badge_Grade)
[](https://www.codacy.com/gh/codacy/codacy-api-scala?utm_source=github.com&utm_medium=referral&utm_content=codacy/codacy-api-scala&utm_campaign=Badge_Coverage)
[](https://circleci.com/gh/codacy/codacy-api-scala/tree/master)
[](https://maven-badges.herokuapp.com/maven-central/com.codacy/codacy-api-scala_2.11)
## Usage
If you use Maven you can declare the dependency:
```xml
com.codacy
codacy-api-java
VERSION
```
First, declare the dependency on SBT:
```xml
"com.codacy" %% "codacy-api-scala" % "VERSION"
```
Usage example (extracted from our [sbt-codacy-coverage tool](https://github.com/codacy/sbt-codacy-coverage/blob/c10e67fa6fe62992c871e9811c41603ae0a76870/src/main/scala/com/codacy/CodacyCoveragePlugin.scala#L56-L69):
```xml
val apiUrl = "https://api.codacy.com/"
val projectToken = "randomizedTokenGeneratedByCodacy"
val codacyClient = new CodacyClient(Some(apiUrl), projectToken = Some(projectToken))
val coverageServices = new CoverageServices(codacyClient)
val commitUUID = "gitCommitUUID"
val report = ...
coverageServices.sendReport(commitUUID, Language.Scala, report) match {
case requestResponse if requestResponse.hasError =>
logger.error(s"Failed to upload data. Reason: ${requestResponse.message}")
state.exit(ok = false)
Left(requestResponse.message)
case requestResponse =>
logger.success(s"Coverage data uploaded. ${requestResponse.message}")
Right(state)
}
```
## Creators
1. Rodrigo Fernandes
## Contributors
1. Rafael Cortês
2. João Machado
3. João Caxaria
4. Pedro Rijo
## What is Codacy
[Codacy](https://www.codacy.com/) is an Automated Code Review Tool that monitors your technical debt, helps you improve your code quality, teaches best practices to your developers, and helps you save time in Code Reviews.
### Among Codacy’s features
- Identify new Static Analysis issues
- Commit and Pull Request Analysis with GitHub, BitBucket/Stash, GitLab (and also direct git repositories)
- Auto-comments on Commits and Pull Requests
- Integrations with Slack, HipChat, Jira
- Track issues in Code Style, Security, Error Proneness, Performance, Unused Code and other categories
Codacy also helps keep track of Code Coverage, Code Duplication, and Code Complexity.
Codacy supports PHP, Python, Ruby, Java, JavaScript, and Scala, among others.
## Free for Open Source
Codacy is free for Open Source projects.
## License
codacy-api-scala is available under the MIT license. See the LICENSE file for more info.