The Access Grid SDK is a Java library for seamlessly interacting with the Access Grid API. It provides a simple, type-safe interface for managing access cards, templates, and performing enterprise-level operations.
- 🔐 Secure API Authentication
- 📇 Access Card Management
- 🏢 Enterprise Template Creation and Management
- 🚀 Easy-to-Use Fluent API
- ☕ Full Java 11+ Support
Add the following dependency to your pom.xml:
<dependency>
<groupId>com.organization</groupId>
<artifactId>access-grid-sdk</artifactId>
<version>1.0.0</version>
</dependency>Add to your build.gradle:
implementation 'com.organization:access-grid-sdk:1.0.0'AccessGridClient client = new AccessGridClient(
System.getenv("ACCESS_GRID_ACCOUNT_ID"),
System.getenv("ACCESS_GRID_SECRET_KEY")
);ProvisionCardRequest request = ProvisionCardRequest.builder()
.cardTemplateId("template-123")
.employeeId("emp-456")
.fullName("John Doe")
.email("john.doe@company.com")
.classification("full_time")
.build();
Card card = client.accessCards().provision(request);
System.out.println("Card Installed: " + card.getUrl());CreateTemplateRequest templateRequest = CreateTemplateRequest.builder()
.name("Employee Access Card")
.platform("apple")
.useCase("employee_badge")
.allowOnMultipleDevices(true)
.build();
Template template = client.console().createTemplate(templateRequest);The SDK uses a custom AccessGridException for error management:
try {
client.accessCards().provision(request);
} catch (AccessGridException e) {
// Handle API-specific errors
System.err.println("Error: " + e.getMessage());
}ACCESS_GRID_ACCOUNT_ID: Your Access Grid account identifierACCESS_GRID_SECRET_KEY: Your API secret key
The SDK uses SLF4J for logging. Configure your preferred logging implementation.
// Suspend a card
client.accessCards().suspend("card-123");
// Resume a card
client.accessCards().resume("card-123");
// Unlink a card
client.accessCards().unlink("card-123");- Java 11+
- Jackson for JSON processing
- SLF4J for logging
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
[Specify your license, e.g., MIT, Apache 2.0]
For issues or questions, please open a GitHub issue or contact support@yourcompany.com.