Actions88
- Blog Actions
- Get All Posts (Admin)
- Get Post (Admin)
- Create Post (Admin)
- Update Post (Admin)
- Delete Post (Admin)
- Get Categories (Admin)
- Get Category (Admin)
- Create Category (Admin)
- Update Category (Admin)
- Delete Category (Admin)
- Get Tags (Admin)
- Get Tag (Admin)
- Create Tag (Admin)
- Update Tag (Admin)
- Delete Tag (Admin)
- Get Authors (Admin)
- Get All Posts (Public)
- Get Post (Public)
- Get Categories (Public)
- Get Tags (Public)
- Get Posts by Category (Public)
- Get Posts by Tag (Public)
- Section Actions
- AI Resource Actions
- Authentication Actions
- User Actions
- Course Actions
- Lecture Actions
- Enrollment Actions
- Learning Path Actions
- Assignment Actions
- Progress Actions
- Video Actions
- Article Actions
- Quiz Question Actions
- Quiz Choice Actions
- Quiz Submission Actions
- Image Actions
Overview
This node integrates with the Lectful API to manage AI resources within an educational platform. Specifically, the Create AI Resource operation allows users to upload and create a new AI resource file (such as PDFs, Word documents, images, spreadsheets, etc.) that can be used in courses or other learning materials.
Typical use cases include:
- Uploading course-related documents or media files to enhance learning content.
- Managing various types of AI resources for automated processing or distribution.
- Integrating external files into an LMS workflow via automation.
For example, you might use this node to upload a PDF syllabus or a PowerPoint presentation to your course repository automatically when new content is created.
Properties
| Name | Meaning |
|---|---|
| Authentication Mode | Choose how to authenticate with the Lectful API: - Use Stored Credentials - Manual Configuration (provide base URL and API key manually) |
| Credentials Note | Informational note shown when using Manual Configuration mode about leaving credentials empty and using overrides instead. |
| Base URL Override | Optional base URL to override the credential setting (without /api/v1). Used only in Manual Configuration mode. |
| API Key Override | Optional API key to override the credential setting. Used only in Manual Configuration mode. |
| Name | Name of the AI resource being created. |
| Type | Type of the AI resource file. Options include: PDF, Word Document (DOC/DOCX), Text File, Excel Spreadsheet (XLS/XLSX), PowerPoint Presentation (PPT/PPTX), JPEG/JPG Image, PNG Image, GIF Image |
| Description | Optional description of the AI resource. |
| File | File URL or binary data to upload (maximum size 10MB). Can be a direct URL or reference to binary data property. |
Output
The node outputs a JSON object representing the response from the Lectful API after creating the AI resource. This typically includes details such as the resource ID, name, type, status, file metadata, timestamps, and any other relevant information returned by the API.
If the file is uploaded as binary data, it is sent as multipart/form-data; however, the output itself is JSON describing the created resource.
Dependencies
- Requires access to the Lectful API endpoint.
- Requires either stored credentials configured in n8n or manual entry of the base URL and API key.
- The API key must have permissions to create AI resources.
- The node uses HTTP requests with authentication headers or n8n's credential system.
- Maximum file size for uploads is 10MB.
Troubleshooting
- Missing or invalid credentials: If neither stored credentials nor manual configuration with valid base URL and API key are provided, the node will throw an error. Ensure credentials are correctly set up or manual parameters are filled.
- File size limit exceeded: Uploads larger than 10MB will likely fail. Check the file size before uploading.
- Invalid file reference: When providing binary data, ensure the binary property name matches exactly and contains valid data.
- API errors: Errors returned from the Lectful API (e.g., unauthorized, bad request) will be surfaced in the node output. Review the error message for guidance.
- Malformed JSON in inputs: For properties expecting JSON strings (not applicable here but common in other operations), ensure valid JSON format.
Links and References
- Lectful API Documentation (Assumed, replace with actual if available)
- n8n Documentation on Working with Binary Data
- n8n Documentation on Credentials
This summary focuses on the "Create AI Resource" operation of the Lectful node, detailing its purpose, input properties, output structure, dependencies, and common troubleshooting tips based on static analysis of the source code and provided property definitions.