Actions132
- AI Actions
- Extract Text From Document
- Check Content Policy
- Detect Adult Content
- Detect Brand
- Detect Color
- Detect Email Type
- Detect Faces
- Extract Entities
- Extract Contact Information
- Extract Customizable Information From Text
- Fuzzy Text Matcher
- Generate Image
- Generate JavaScript Code
- Generate Python Code
- Detect Language
- Detect Mood
- Extract Text From PDF
- Recognize Objects in Image
- Extract Text From Image
- Redact Sensitive Information From PDF
- Remove Background Image
- Summarize Text
- Transcribe
- Translate Text
- Image Actions
- Business Actions
- Convert Actions
- Generate Actions
- Crypto Actions
- Operator Actions
- Storage Actions
- Scheduler Actions
- Text Actions
- Chart Actions
- Code Actions
- Calculate Actions
- Date and Time Actions
- PDF Actions
- Compress PDF File
- Count PDF Pages
- Create Empty PDF
- Decrypt PDF
- Convert DOCX to PDF
- Draw Image on PDF
- Draw Text on PDF
- Encrypt PDF
- Convert HTML to PDF
- Convert Markdown to PDF
- Manage PDF Metadata
- Merge PDF Files
- Add PDF Pages
- Remove PDF Pages
- Resize PDF Pages
- Rotate PDF Pages
- Convert PDF to Base64
- Convert PDF to Image
- Split PDF File
- Add Image Watermark to PDF
- Add Text Watermark to PDF
- Shortened URL Actions
Chart → Bars Chart
AI-generatedOverview
The node generates bar charts based on user-provided data points and labels. It is useful for visualizing numerical data in a clear, graphical format, such as sales figures over months, survey results, or performance metrics. Users can customize the chart's appearance including colors, size, and title. The output can be either an image file or a URL pointing to the generated chart.
Practical examples:
- Visualizing monthly sales data with labeled bars.
- Creating a quick report graphic for presentation slides.
- Generating dynamic charts for dashboards or automated reports.
Properties
| Name | Meaning |
|---|---|
| Data Points | Array of numbers representing the values for each bar in the chart (e.g., [10, 20, 30]). |
| Labels | Array of strings labeling each data point/bar (e.g., ["Jan", "Feb", "Mar"]). |
| Chart Title | Optional string to set the title displayed on the chart (e.g., "Sales by Month"). |
| Background Color | Hex color code defining the background color of the chart image (e.g., #ffffff for white). |
| Bar Colors | Array of hex color codes for the fill color of each bar (e.g., ["#36A2EB", "#FF6384"]). |
| Border Colors | Array of hex color codes for the borders around each bar (e.g., ["#36A2EB", "#FF6384"]). |
| Border Width | Number specifying the width of the border around each bar in pixels (e.g., 1). |
| Return as URL | Boolean indicating if the output should be a URL to the chart image instead of the image itself. |
| File Name | Optional string to specify the filename for the generated chart image (e.g., "bar-chart.png"). |
| Width | Number specifying the width of the chart image in pixels (e.g., 800). |
| Height | Number specifying the height of the chart image in pixels (e.g., 600). |
Output
The node outputs JSON data containing the generated bar chart. Depending on the "Return as URL" property:
- If false: The output includes the binary image data of the chart, which can be saved or used directly within workflows.
- If true: The output contains a URL string pointing to the hosted chart image.
The output JSON structure typically includes fields for the image data or URL, along with metadata such as filename if provided.
Dependencies
- Requires an API key credential for authentication with the external chart generation service at
https://prod.0codekit.com. - The node sends a POST request to
/generate/chart/barsendpoint with the chart parameters. - No additional local dependencies are needed; all processing is handled via the external API.
Troubleshooting
- Invalid JSON input for Data Points or Labels: Ensure that the arrays are valid JSON and that the number of labels matches the number of data points.
- API Authentication Errors: Verify that the API key credential is correctly configured and has necessary permissions.
- Chart Generation Failures: Check that color codes are valid hex strings and dimensions are positive integers.
- Empty or Missing Required Fields: Make sure required properties like Data Points and Labels are provided.
- Output URL not accessible: If returning a URL, ensure network access to the external service and that the URL is valid.
Links and References
- 0CodeKit API Documentation (for detailed API usage and authentication)
- General charting concepts: https://www.chartjs.org/docs/latest/charts/bar.html