Liferay
Liferay is an open-source digital experience platform for enterprise content management (ECM) and portal development.
Categories: Productivity and Collaboration
Type: liferay/v1
Connections
Version: 1
OAuth2
Properties
| Name | Label | Type | Description | Required |
|---|---|---|---|---|
| clientId | Client ID | STRING | true | |
| clientSecret | Client Secret | STRING | true |
API Key
Properties
| Name | Label | Type | Description | Required |
|---|---|---|---|---|
| key | Key | STRING | true | |
| value | Value | STRING | true | |
| addTo | Add to | STRING OptionsHEADER, QUERY_PARAMETERS | true |
Bearer Token
Properties
| Name | Label | Type | Description | Required |
|---|---|---|---|---|
| token | Token | STRING | true |
Basic Auth
Properties
| Name | Label | Type | Description | Required |
|---|---|---|---|---|
| username | Username | STRING | true | |
| password | Password | STRING | true |
Connection Setup
API Key
Bearer Token
- Click on Open Application Menu.
- Navigate to Settings → APIs to generate an access token.
- Choose the duration (e.g. 30 days, 6 months, 1 year, or indefinite) for when the access token expires.
- Click Generate Token.
- To use the new token, click Copy and paste it into Bytechef connection.
Basic Auth
- Use your username and password to create Liferay connection in Bytechef.
OAuth
- Navigate to your Liferay portal.
- Click this icon to open Applications Menu.
- Click on Control Panel
- Click on OAuth 2 Administration
- Click on New
- Enter name of your OAuth application.
- Enter a redirect URI, e.g.,
https://app.bytechef.io/callback,http://127.0.0.1:5173/callback - Enable Trusted Application.
- Click on Save
- Here you can see your Client ID and Client Secret.
- Click on Scopes
- Click on Liferay.Headless.Discovery.OpenAPI
- Enable scopes you need.
- Click on Save
- Done 🚀
Actions
Headless Request
Name: headlessRequest
Executes a Liferay Headless API action using the configured endpoint.
Properties
| Name | Label | Type | Description | Required |
|---|---|---|---|---|
| application | Application | STRING | Liferay REST Application you want to use. | true |
| endpoint | Endpoint | STRING Depends Onapplication | API endpoint where requests are sent. | true |
| properties | DYNAMIC_PROPERTIES Depends Onapplication, endpoint | false |
Example JSON Structure
{
"label" : "Headless Request",
"name" : "headlessRequest",
"parameters" : {
"application" : "",
"endpoint" : "",
"properties" : { }
},
"type" : "liferay/v1/headlessRequest"
}Output
The output for this action is dynamic and may vary depending on the input parameters. To determine the exact structure of the output, you need to execute the action.
JSON WS Services
Name: jsonWsRequest
Sends a JSON-based HTTP request to a configured external web service endpoint.
Properties
| Name | Label | Type | Description | Required |
|---|---|---|---|---|
| contextName | Context Name | STRING Optionsportal, account, asset, assetlist, audit, backgroundtask, batchengine, blogs, calendar, comment, commerce, contact, ct, ddl, ddm, depot, dispatch, fragment, journal, kaleo, kaleoforms, kb, layout, layoututilitypage, listtype, marketplace, mb, notification, oauthclient, object, portallanguageoverride, redirect, remoteapp, sap, savedcontententry, segments, sharing, sitenavigation, stylebook, sxp, translation, trash, wiki | Context name of JSON web service you want to use. | true |
| service | Service ID | INTEGER Depends OncontextName | ID of the service you want to access. | true |
| parameters | DYNAMIC_PROPERTIES Depends Onservice | true |
Example JSON Structure
{
"label" : "JSON WS Services",
"name" : "jsonWsRequest",
"parameters" : {
"contextName" : "",
"service" : 1,
"parameters" : { }
},
"type" : "liferay/v1/jsonWsRequest"
}Output
The output for this action is dynamic and may vary depending on the input parameters. To determine the exact structure of the output, you need to execute the action.
Find Context Name and Service ID
To find the Context Name, click here.
To find the Service ID, click here.
What to do if your action is not listed here?
If this component doesn't have the action you need, you can use Custom Action to create your own. Custom Actions empower you to define HTTP requests tailored to your specific requirements, allowing for greater flexibility in integrating with external services or APIs.
To create a Custom Action, simply specify the desired HTTP method, path, and any necessary parameters. This way, you can extend the functionality of your component beyond the predefined actions, ensuring that you can meet all your integration needs effectively.
Additional Instructions
How to find the Application
- Method 1: Via API
Use the GET /o/openapi/openapi.json endpoint to retrieve a list of all applications.
- *Method 2: Via UI
Go to [server]:[port]/o/api, click on REST Applications and there you have a list of all applications.
How to find the Endpoint
- Method 1: Via API
Use the GET /o/APPLICATION/openapi.json" endpoint to retrieve a list of all endpoints in specific application.
- *Method 2: Via UI
Go to [server]:[port]/o/api, choose the REST Application you want and there you have a list of all endpoints.
If endpoint starts with a version, you need to remove that part. For example if endpoint is /v1.0/accounts, your need to use /accounts.
How to find the Context Name
- *Method 1: Via UI
Go to [server]:[port]/api/jsonws, click on Context Name and there you have a list of all contexts.
How to find the Service ID
- Method 1: Via API
Use the GET "/api/jsonws?contextName=CONTEXT_NAME&discover="" endpoint to retrieve a list of all service IDs in specific context.
How is this guide?
Last updated on