{"id":21406712,"url":"https://github.com/ringcentral/ringcentral-java","last_synced_at":"2025-07-14T00:32:47.709Z","repository":{"id":40369734,"uuid":"55440696","full_name":"ringcentral/ringcentral-java","owner":"ringcentral","description":"RingCentral Java SDK","archived":false,"fork":false,"pushed_at":"2025-06-16T17:32:10.000Z","size":11838,"stargazers_count":22,"open_issues_count":4,"forks_count":23,"subscribers_count":13,"default_branch":"master","last_synced_at":"2025-06-16T18:42:19.466Z","etag":null,"topics":["java","ringcentral","sdk"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ringcentral.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2016-04-04T20:00:47.000Z","updated_at":"2025-06-16T17:31:57.000Z","dependencies_parsed_at":"2025-06-16T18:30:38.319Z","dependency_job_id":"ae6b9344-7bf8-4b21-b7cd-34e2c94eb1b7","html_url":"https://github.com/ringcentral/ringcentral-java","commit_stats":null,"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"purl":"pkg:github/ringcentral/ringcentral-java","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringcentral%2Fringcentral-java","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringcentral%2Fringcentral-java/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringcentral%2Fringcentral-java/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringcentral%2Fringcentral-java/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ringcentral","download_url":"https://codeload.github.com/ringcentral/ringcentral-java/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringcentral%2Fringcentral-java/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265227898,"owners_count":23731059,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","ringcentral","sdk"],"created_at":"2024-11-22T16:42:01.811Z","updated_at":"2025-07-14T00:32:42.685Z","avatar_url":"https://github.com/ringcentral.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RingCentral SDK for Java\n\n[![Build Status](https://github.com/ringcentral/ringcentral-java/actions/workflows/test.yml/badge.svg)](https://github.com/ringcentral/ringcentral-java/actions)\n[![Coverage Status](https://coveralls.io/repos/github/ringcentral/ringcentral-java/badge.svg?branch=master)](https://coveralls.io/github/ringcentral/ringcentral-java?branch=master)\n[![Reference](https://img.shields.io/badge/Javadoc-reference-blue?logo=java)](https://ringcentral.github.io/ringcentral-java/javadoc)\n[![Chat](https://img.shields.io/badge/chat-on%20glip-orange.svg)](https://ringcentral.github.io/join-ringcentral/)\n[![Twitter](https://img.shields.io/twitter/follow/ringcentraldevs.svg?style=social\u0026label=follow)](https://twitter.com/RingCentralDevs)\n\n__[RingCentral Developers](https://developer.ringcentral.com/api-products)__ is a cloud communications platform which\ncan be accessed via more than 70 APIs. The platform's main capabilities include technologies that enable:\n\n* [Voice](https://developer.ringcentral.com/api-products/voice)\n* [SMS/MMS](https://developer.ringcentral.com/api-products/sms)\n* [Fax](https://developer.ringcentral.com/api-products/fax)\n* [Team Messaging](https://developer.ringcentral.com/api-products/team-messaging)\n* [Data and Configurations](https://developer.ringcentral.com/api-products/configuration)\n* [Video](https://developers.ringcentral.com/video-api)\n* [RingSense AI](https://developers.ringcentral.com/ai-api)\n* [Webinar](https://developers.ringcentral.com/webinar-api)\n* [Business Analytics](https://developers.ringcentral.com/analytics-api).\n\n## Additional resources\n\n* [RingCentral API Reference](https://developer.ringcentral.com/api-docs/latest/index.html) - an interactive reference\n  for the RingCentral API that allows developers to make API calls with no code.\n* [Document](https://ringcentral.github.io/ringcentral-java/javadoc) - an interactive reference for the SDK code\n  documentation.\n\n## Getting help and support\n\nIf you are having difficulty using this SDK, or working with the RingCentral API, please visit\nour [developer community forums](https://community.ringcentral.com/index.html) for help and to get quick answers to\nyour questions. If you wish to contact the RingCentral Developer Support team directly,\nplease [submit a help ticket](https://developers.ringcentral.com/support/create-case) from our developer website.\n\n## Installation\n\nThis SDK is tested against JDK 11 so we recommend using the same. Earlier versions such as Java 8 should work as well,\nplease report issues if you encounter any.\n\n### Gradle\n\n```groovy\nrepositories {\n  mavenCentral()\n}\n\ndependencies {\n  implementation 'com.ringcentral:ringcentral:[version]'\n}\n```\n\nDon't forget to replace `[version]` with expected version. You can find the latest versions\nin [Maven Central](https://search.maven.org/search?q=a:ringcentral).\n\n### Maven\n\n```xml\n\u003cdependency\u003e\n  \u003cgroupId\u003ecom.ringcentral\u003c/groupId\u003e\n  \u003cartifactId\u003eringcentral\u003c/artifactId\u003e\n  \u003cversion\u003e[version]\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nDon't forget to replace `[version]` with expected version. You can find the latest versions\nin [Maven Central](https://search.maven.org/search?q=a:ringcentral).\n\n### Manually\n\n[Download jar here](https://search.maven.org/classic/#search%7Cga%7C1%7Ca%3A%22ringcentral%22) and save it into your\njava classpath.\n\n## Usage\n\n### Initialization \u0026 Authorization Using jwtToken\n\n```java\nRestClient rc = new RestClient(clientId, clientSecret, server);\nrc.authorize(jwtToken);\n\n// do something with `rc`\n\nrc.revoke();\n```\n\n#### Below are some pointers which help to understand the JWT authorization flow\n\n* [JWT authorization code flow](https://developers.ringcentral.com/guide/authentication/jwt-flow)\n* [Configuring apps to use JWT](https://developers.ringcentral.com/guide/authentication/jwt/config-app)\n* [CreateJWT](https://developers.ringcentral.com/guide/getting-started/create-credential)\n\nFor the `server` parameter, there are two static final string variables in `RestClient`:\n\n```java\npublic static final String PRODUCTION_SERVER = \"https://platform.ringcentral.com\";\n```\n\n### What is a Client ID and Client Secret used for?\n\nEach app you build must first be registered in the RingCentral Developer Console. Upon doing so, you will receive a\nClient ID and Client Secret that together uniquely identify your application on our platform. A public app could be used\nby many companies while a private app can only be used by your current company.\n\n### Token refresh\n\nSince 1.0 version, the SDK by default does NOT do auto token refresh.\nThis is because most of the time it's better to manage token lifecycle manually: `rc.refresh()`.\n\nFor simple apps, token auto refresh could be beneficial. So we provide a sugar method: `rc.autoRefresh()`.\nThis method will start a background timer to refresh token for you every 30 minutes.\nYou can customize the refresh period, for example, change it to every 50 minutes: `rc.autoRefresh(1000 * 60 * 50)`.\n\n## Code samples\n\nYou can find [sample code for all the endpoints](./samples.md).\n\nThere is also lots of useful code for your reference in our [test cases](./src/test/java/com/ringcentral).\n\n## Logging\n\nThe logging is implemented according\nto [Java Logging Overview](https://docs.oracle.com/javase/10/core/java-logging-overview.htm)\n\nTo enable printing log to the console:\n\n```java\nRestClient.logger.setLevel(Level.FINE);\n```\n\nFor more log output channels, please refer\nto [Handlers](https://docs.oracle.com/javase/10/core/java-logging-overview.htm#GUID-B83B652C-17EA-48D9-93D2-563AE1FF8EDA__HANDLERS-4D023767)\n.\n\n[Demo project](https://github.com/tylerlong/rc-logging-demo-java).\n\n## Binary content downloading\n\nSome [sample code](./samples.md) for binary content downloading may not work.\n\nBecause RingCentral is gradually migrating binary content to CDN such as `media.ringcentral.com`.\n\nFor example, to download the attachment of a fax:\n\n```java\n// `message` is the fax message object\nbyte[] content = rc.get\u003cbyte[]\u003e(message.attachments[0].uri).bytes();\n```\n\nThe following does **NOT** work:\n\n```java\n// `message` is the fax message object\nbyte[] content = rc.restapi().account().extension().messageStore(message.id).content(message.attachments[0].id).get();\n```\n\n### Rule of thumb\n\nBut not all binary content has been migrated to CDN.\nIf the resource to download provides you with a CDN uri, use that CDN uri.\nIf there is no CDN uri provided, construct the uri as the [sample code](./samples.md) shows.\n\n## Subscriptions \u0026 notifications\n\n### WebSocket\n\nPlease refer to the [RingCentral WebSocket SDK for Java](https://github.com/ringcentral/ringcentral-websocket-java)\nproject.\n\n### (Deprecated) PubNub\n\nPlease refer to the [RingCentral PubNub SDK for Java](https://github.com/ringcentral/ringcentral-pubnub-java) project.\n\n## Release Notes\n\n### 3.0.0\n\nWe have renamed all \"glip\" to \"team-messaging/v1\". For example:\n\n```java\nrc.restapi().glip()...\n```\n\nbecomes\n\n```java\nrc.teamMessaging().v1()...\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fringcentral%2Fringcentral-java","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fringcentral%2Fringcentral-java","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fringcentral%2Fringcentral-java/lists"}