Releases: slackapi/java-slack-sdk
Releases · slackapi/java-slack-sdk
version 1.41.0
Announcements
Support for custom steps
Bolt for Java now supoports the way to build custom steps in Workflow Builder. Here is a quick example demonstrating how it works:
app.function("sample_function", (req, ctx) -> {
app.executorService().submit(() -> {
try {
var userId = req.getEvent().getInputs().get("user_id").asString();
var response = ctx.client().chatPostMessage(r -> r
.channel(userId) // sending a DM
.text("Hi! Thank you for submitting the request! We'll let you know once the processing completes.")
);
var outputs = new HashMap<String, Object>();
outputs.put("channel_id", response.getChannel());
outputs.put("ts", response.getTs());
ctx.complete(outputs);
} catch (Exception e) {
ctx.logger.error(e.getMessage(), e);
try {
ctx.fail("Failed to handle 'sample_function' custom step execution (error: " + e.getMessage() + ")");
} catch (Exception ex) {
ctx.logger.error(e.getMessage(), e);
}
}
});
return ctx.ack();
});
The App Manifest for the custom step would be something like this:
"functions": {
"sample_function": {
"title": "Send a request",
"description": "Send some request to the backend",
"input_parameters": {
"user_id": {
"type": "slack#/types/user_id",
"title": "User",
"description": "Who to send it",
"is_required": true,
"hint": "Select a user in the workspace",
"name": "user_id"
}
},
"output_parameters": {
"channel_id": {
"type": "slack#/types/channel_id",
"title": "DM ID",
"description": "The DM ID",
"is_required": true,
"name": "channel_id"
},
"ts": {
"type": "string",
"title": "Message timestamp",
"description": "Sent message timestamp",
"is_required": true,
"name": "ts"
}
}
}
}
Please refer to https://api.slack.com/automation/functions/custom-bolt for more details!
Changes
- [bolt] #1241 Add custom function support - Thanks @seratch
- [bolt][slack-app-backend] #1351 #1343 block_suggestion response does not support description in an option - Thanks @ESteanes @seratch
- [slack-api-client] #1346 Fix a bug where filename & title getting improperly defaulted in filesUploadV2 - Thanks @Cheos137
- [slack-api-client] Add missing properties in web API responses - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/104?closed=1
- All changes: v1.40.3...v1.41.0
version 1.40.3
Changes
- [slack-api-client] #1337 Fix #1336 missing and invalid properties in rich text block elements - Thanks @seratch @Falit
- [slack-api-client] Add new properties to Web API responses - Thanks @seratch
- [bolt] Add missing properties in app_mention event payload - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/103?closed=1
- All changes: v1.40.2...v1.40.3
version 1.40.2
Changes
- [slack-api-client] #1330 Add conversations.externalInvitePermissions.set API support - Thanks @seratch
- [slack-api-client] #1331 Add team.externalTeams.disconnect API - Thanks @seratch
- [bolt] #1332 Add a few missing event data types - Thanks @seratch
- [slack-api-client] Add new properties to Web API responses - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/102?closed=1
- All changes: v1.40.1...v1.40.2
version 1.40.1
Changes
- [slack-api-client] #1327 Add team.externalTeams.list API support - Thanks @seratch
- [slack-api-client] Add new properties to Web API responses - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/100?closed=1
- All changes: v1.40.0...v1.40.1
version 1.40.0
Changes
- [slack-api-client] #1323 Add canvas APIs and users.discoverableContacts.lookup API - Thanks @filmaj @seratch
- [all] #1319 Add deprecation warnings to Steps from Apps components - Thanks @seratch
- [slack-api-client] Add new properties to Web API responses - Thanks @seratch
- [documents] Mark "Steps from Apps" as deprecated - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/99?closed=1
- All changes: v1.39.3...v1.40.0
version 1.39.3
Changes
- [slack-api-client] #1316 Fix #1314 files.upload v2 method does not upload multiple files with full metadata - Thanks @oppokui @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/99?closed=1
- All changes: v1.39.2...v1.39.3
version 1.39.2
Changes
- [slack-api-client] #1312 Fix #1311 entity.message is missing in Audit Logs API response - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/98?closed=1
- All changes: v1.39.1...v1.39.2
version 1.39.1
Changes
- [slack-api-client] #1298 Mark files.upload / rtm.connect as deprecated - Thanks @seratch
- [slack-api-client] #1310 Fix #1308 repsonse_metadata is missing in admin.initeRequests.list/*.list response classes - Thanks @Dunkhell @seratch
- [slack-api-client] Add new properties to Web API responses - Thanks @seratch
Test improvements:
- #1296 #892 Run all tests using JDK 17 - Thanks @hrothwell
- #1302 Fix codecov CI errors - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/96?closed=1
- All changes: v1.39.0...v1.39.1
version 1.39.0
Changes
- [slack-api-client] Add support for micronaut 4 - Thanks @hrothwell
- [slack-api-client] Many property addition to Web API response types - Thanks @seratch
- All issues/pull requests: https://github.com/slackapi/java-slack-sdk/milestone/90?closed=1
- All changes: v1.38.3...v1.39.0
version 1.38.3
Changes
- [slack-api-client] Add new properties to Web API responses - Thanks @seratch
- All changes: v1.38.2...v1.38.3