### Install Kreya on Linux via Snapcraft Source: https://kreya.app/docs/getting-started This snippet shows the command to install Kreya using Snapcraft on Linux. Ensure you have Snapcraft installed and configured on your system. ```bash sudo snap install kreya ``` -------------------------------- ### Install Kreya on Linux via Tarball Source: https://kreya.app/docs/getting-started This snippet outlines the manual installation process for Kreya on Linux using a tarball. It also highlights the necessary dependencies: libgtk-3 and libwebkit2gtk-4.0. ```bash # Download the tarball # Extract the tarball # Ensure libgtk-3 and libwebkit2gtk-4.0 are installed # Run the Kreya executable ``` -------------------------------- ### gRPC Example API URL Source: https://kreya.app/docs/getting-started This snippet shows how to enter an example API URL for gRPC services when setting up an importer in Kreya. This allows Kreya to automatically generate operations for the gRPC service methods. ```APIDOC Importer Setup: - Importer Type: gRPC - Protobuf Definition Source: https://example-api.kreya.app:9090 - API URL: https://example-api.kreya.app:9090 (Prefilled for all operations) ``` -------------------------------- ### Windows Defender Smart Screen Warning Source: https://kreya.app/docs/getting-started This describes the potential Windows Defender Smart Screen warning during Kreya installation and the steps to bypass it. This is due to Kreya's code signature not being fully trusted by Windows yet. ```powershell # During installation, if a Windows Defender Smart Screen warning appears: # Click on "More info" # Click on "Run anyway" ``` -------------------------------- ### Sending Your First Request Source: https://kreya.app/docs/getting-started This guide explains how to send your first request after setting up your project and API URL. It directs users to the settings tab to input the service URL in the 'Endpoint' field and then click the 'Send' button to execute an operation. ```APIDOC Sending Request: 1. Navigate to Settings Tab. 2. Enter Service URL in the 'Endpoint' input field. 3. Click the 'Send' button to execute an operation. ``` -------------------------------- ### Adding OpenAPI Definitions for REST Source: https://kreya.app/docs/getting-started This section details how to integrate REST services by providing OpenAPI definitions. It explains the process of selecting an importer type, entering necessary information, and using an example OpenAPI JSON URL to generate operations. It also mentions setting the API URL for all operations. ```APIDOC OpenAPI Definition Import: Select Importer Type: Choose the type of importer for your REST service. Enter Information: Provide the required details for the selected importer. Example URL: https://example-api.kreya.app/swagger/v1/swagger.json Action: Click 'Next' to proceed. API URL Configuration: Purpose: Set the base URL for all generated operations. Input Field: 'Endpoint' in the settings tab. Action: Enter the service URL. ``` -------------------------------- ### Example JSON Configuration File Source: https://kreya.app/docs/configuration This snippet shows a typical JSON configuration file for the Kreya application. It includes settings for maximum response size, scripting timeout, and logging levels. ```json { "RestMaxResponseSize": 1048576, "ScriptingTimeout": 30000, "Logging": { "LogLevel": { "Default": "Warning", "Kreya": "Information" } } } ``` -------------------------------- ### Kreya CLI Project Create Example Source: https://kreya.app/docs/cli/commands/project/create An example demonstrating how to use the 'project create' command to create a project named 'my-project'. ```cli kreyac project create my-project ``` -------------------------------- ### Kreya CLI: collection invoke example Source: https://kreya.app/docs/cli/commands/collection/invoke Example of how to invoke a collection using the Kreya CLI, specifying the project file and the collection file. ```bash kreyac collection invoke -p ./my-directory/my-project.krproj my-collection.krcol ``` -------------------------------- ### Example Request to Docker API via Unix Socket Source: https://kreya.app/docs/unix-sockets Provides a step-by-step guide to configure a request in Kreya to interact with the Docker API using a Unix socket. It includes setting the endpoint, HTTP method, and path. ```APIDOC Endpoint: unix:///var/run/docker.sock Method: GET Path: /containers/json ``` -------------------------------- ### Kreya App Bug Fix: Startup Error Dialog Source: https://kreya.app/docs/release-notes Displays an error message box if Kreya fails to start. ```APIDOC Startup Error Dialog: - Show an error message box if Kreya fails to start. ``` -------------------------------- ### Path Module Import and Usage Example Source: https://kreya.app/docs/scripting-and-tests/general/path-script-api Demonstrates how to import and use the 'join' function from the 'path' module to construct a gRPC operation path. ```javascript import { join } from "path"; const grpcOperationPath = join("../", "gRPC", "my-operation"); ``` -------------------------------- ### Kreya CLI Operation Invoke Example Source: https://kreya.app/docs/cli Demonstrates how to use the Kreya CLI to invoke operations within a project, showing both gRPC and REST operations and their success status. ```bash $ kreyac operation invoke -p example-project scripting Invoking operation scripting/Scripting gRPC.krop [0] OK 560msInvoking operation scripting/Scripting REST.krop [200] OKAll 9 tests completed successfully ``` -------------------------------- ### Kreya UI - Add Environment via Switcher Source: https://kreya.app/docs/release-notes Add a new environment directly from the environment switcher if no environments are currently configured, simplifying initial setup. ```javascript // When no environment is selected, the switcher provides an option to create a new one. ``` -------------------------------- ### Kreya Scripting Examples Source: https://kreya.app/docs/scripting-and-tests/invoker-scripts/api-reference Demonstrates how to use the Kreya scripting API to trace script execution, invoke operations, and handle results with retries and delays. ```javascript kreya.trace('Starting script invocation of '+ kreya.script.current.name); await kreya.invokeOperation('my-gRPC-operation'); let success =false; while(!success){ const result =await kreya.invokeOperation('my-rest-operation'); success = result.success; kreya.sleep(100); } ``` -------------------------------- ### Protobuf Import Path Example Source: https://kreya.app/docs/importers/grpc Illustrates a common Protobuf project structure where one proto file imports another using relative paths. It highlights the necessity of including the base directory ('/src') as an import path for successful resolution. ```protobuf /src /todo todo.proto /list todo-list.proto (imports todo/todo.proto) ``` -------------------------------- ### Basic Operation Scripting Example Source: https://kreya.app/docs/scripting-and-tests/operation-scripts/operation-script-api-reference Demonstrates basic usage of the Kreya operation script API, including tracing messages, checking for variables, and sleeping. It shows how to interact with the `kreya` namespace to log information and manage script execution flow. ```javascript kreya.trace('Starting operation invocation of '+ kreya.operation.current.name); // Wait until some other operation sets this variable while(!kreya.variables.has('my_var')){ kreya.sleep(10); } kreya.trace('Variable my_var has been set to '+ kreya.variables.get('my_var')); ``` -------------------------------- ### Unix Socket Relative Path Example Source: https://kreya.app/docs/unix-sockets Demonstrates how to use a relative path from the Kreya project root to specify a Unix socket endpoint. ```APIDOC unix://../../relative/path/to/socket ``` -------------------------------- ### Kreya CLI: script invoke command Source: https://kreya.app/docs/cli/commands/script/invoke This snippet shows the basic syntax for invoking scripts using the Kreya CLI. It includes the command structure and an example of its usage with a project file and script. ```bash kreyac script invoke [--test-report-junit][Scripts] Example: kreyac script invoke -p ./my-directory/my-project.krproj my-script.krjs ``` -------------------------------- ### Kreya Configuration Options Source: https://kreya.app/docs/configuration Lists available configuration options for Kreya, including their corresponding JSON keys and environment variable names. This covers settings for disabling auto-updates, logging levels, REST response size, scripting timeouts, telemetry, and history entries. ```APIDOC JSON Key | Environment Variable | Description ---|---|--- `DisableAutoUpdates` | `KREYA_DisableAutoUpdates` | Disables automatic updates. `Logging.LogLevel.Default` | `KREYA_Logging_LogLevel_Default` | Configures the default log level. Available levels are `None`, `Critical`, `Error`, `Warning`, `Information` and `Debug`. `Logging.LogLevel.{Category}` | `KREYA_Logging_LogLevel_{Category}` | Configures the log level of a logging category. Available categories are `KREYA` and `SYSTEM`. `RestMaxResponseSize` | `KREYA_RestMaxResponseSize` | Sets the maximum response size for REST APIs. `ScriptingTimeout` | `KREYA_ScriptingTimeout` | Configures the timeout for scripts. `DisableTelemetry` | `KREYA_DisableTelemetry` | Disables telemetry data collection. `MaxHistoryEntries` | `KREYA_MaxHistoryEntries` | Configures the maximum number of history entries. `MaxHistoryEntriesPerProject` | `KREYA_MaxHistoryEntriesPerProject` | Configures the maximum number of history entries per project. `MaxHistoryEntriesPerOperation` | `KREYA_MaxHistoryEntriesPerOperation` | Configures the maximum number of history entries per operation. ``` -------------------------------- ### Kreya WebSocket Scripting Example Source: https://kreya.app/docs/scripting-and-tests/operation-scripts/websocket-script-api-reference Demonstrates how to use the kreyaWebSocket API to handle WebSocket messages and call completions. It includes setting up listeners for response messages and call completion events, along with basic assertions using chai. ```javascript import{ expect }from'chai'; let responseCount =0; kreyaWebSocket.onResponseMessage(response=>{ responseCount++; kreya.test('Response content',()=>expect(response.content).to.contain(`Message ${responseCount}`)); }); kreyaWebSocket.onCallCompleted(call=>{ kreya.trace('The WebSocket call completed.'); kreya.test('Status code',()=>expect(call.status.code).to.equal(1000)); }); ``` -------------------------------- ### gRPC Script API Usage Example Source: https://kreya.app/docs/scripting-and-tests/operation-scripts/grpc-script-api-reference Demonstrates how to use the `kreyaGrpc` namespace in operation scripts to handle gRPC responses and call completion. It includes testing response content and call status. ```javascript import{ expect }from'chai'; let names =[]; kreyaGrpc.onResponse(msg=>{ kreya.test('Size should be ok',()=>expect(msg.size).to.be.gt(10)); kreya.test('Greeting should start with Hello',()=>expect(msg.content.greeting.startsWith('Hello')).to.be.true); // Store all received names to use them when the gRPC call completes names.push(msg.content.greeting.substr('Hello '.length)); }); kreyaGrpc.onCallCompleted(call=>{ kreya.test('Status should be ok',()=>expect(call.status.code).to.equal(0)); kreya.trace(`Got ${call.responseCount} names: ${names.join(', ')}`); }); ``` -------------------------------- ### Guid API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Provides functionality for generating and manipulating Globally Unique Identifiers (GUIDs). It includes properties for variant and version, and a method to convert the GUID to a string. ```APIDOC Guid: typeGuid={ variant:number; version:number; toString:string; }; Properties: readonly variant:number; readonly version:number; Methods: toString():string; Returns: string ``` -------------------------------- ### Get Suffix Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Gets a random suffix for a name. This function returns a string representing the suffix. ```typescript suffix():string; ``` -------------------------------- ### gRPC Proto File Documentation in Script Editor Source: https://kreya.app/docs/release-notes View documentation for imported proto files directly within the script editor's autocompletion, enhancing developer experience for gRPC interactions. ```javascript // Autocompletion will show documentation for imported proto types and methods. ``` -------------------------------- ### Core Features (1.11.0) Source: https://kreya.app/docs/release-notes Introduces new core features including options to purge user variables, a tour for new users, and support for Linux ARM builds and snapcraft. ```English Core: add option to purge user variables Core: add tour for new users Core: build linux arm Core: linux arm snapcraft support ``` -------------------------------- ### Kreya CLI info command Source: https://kreya.app/docs/cli/commands/info Prints information about the Kreya application and the project. This is the basic usage of the command. ```bash kreyac info ``` -------------------------------- ### Kreya Base Script API - GUID and Hash Generation Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Provides functions to generate universally unique identifiers (GUIDs) and random hexadecimal hash strings. The `hash` function allows customization of length and case. ```APIDOC guid(): Guid; Get a random GUID. Returns: Guid hash(length?:number, upperCase?:boolean):string; Return a random hex hash. Default 40 characters, aka SHA-1. Parameters: length?: number: The length of the hash string. Default, 40 characters, aka SHA-1. upperCase?: boolean: Returns the hex string with uppercase characters. Returns: string ``` -------------------------------- ### Running Operations Concurrently Source: https://kreya.app/docs/scripting-and-tests/invoker-scripts This script illustrates how to run multiple operations concurrently. It starts a long-running operation without awaiting its completion immediately, allowing other operations to be invoked and executed in the meantime. Finally, it awaits the completion of the initially started long-running operation. ```javascript // Start an operation, but do not wait for its completion (no await keyword) const runningOperation = kreya.invokeOperation('long-running'); // Invoke some other operations in the meantime await kreya.invokeOperation('operation1'); await kreya.invokeOperation('operation2'); // Now we wait for the long-running operation to complete await runningOperation; ``` -------------------------------- ### Waiting for Long-Running Job Completion Source: https://kreya.app/docs/scripting-and-tests/invoker-scripts This script demonstrates how to invoke an operation that starts a long-running job, poll its status, and then fetch the result and perform tests once it's finished. It uses `kreya.invokeOperation` to start the job and check its status, and `kreya.sleep` to pause between status checks. ```javascript await kreya.invokeOperation('start-long-running-job'); let finished = false; while(!finished){ const result = await kreya.invokeOperation('fetch-job-status'); finished = result.success; if(!finished){ kreya.sleep(500); } } await kreya.invokeOperation('fetch-job-result'); ``` -------------------------------- ### Core Bug Fixes (1.11.0) Source: https://kreya.app/docs/release-notes Resolves core bugs concerning the about window, Windows installation paths, inherited operation settings, deletion of unsaved changes, relative paths for resources, Windows installer and WebView2, scripting type definitions, and error details display. ```English Core: about window can now be opened during fullscreen on macos Core: correct windows installation path Core: correctly reevaluate inherited, templated operation settings Core: delete of operations and directories with unsaved changes Core: do not try to store relative paths for resources on a different drive Core: improve Windows installer and WebView2 detection Core: resolve scripting type definitions correctly when switching operation tabs Core: show error details in the ui for well known exceptions ``` -------------------------------- ### Using Response Files with Kreya CLI Source: https://kreya.app/docs/cli/global-options Demonstrates how to use response files (flag files) with the Kreya CLI to manage command-line arguments. This is useful for complex commands or reusable configurations. ```bash kreyac @options.txt ``` ```bash operation invoke grpc/** !grpc/not-tested rest/** !rest/not-tested ``` -------------------------------- ### Kreya CLI Info Command Source: https://kreya.app/docs/category/commands Prints information about the Kreya application and the current project. ```APIDOC info Description: Prints information about the app and the project. Usage: kreyac info [options] Options: --help: Show help for the info command. ``` -------------------------------- ### Get Prefix Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves the prefix for a name. This function returns a string representing the prefix. ```typescript prefix():string; ``` -------------------------------- ### Generate UUID Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Generates a random Globally Unique Identifier (GUID). This is an alias for the Randomizer.Guid() method. ```typescript uuid(): Guid; ``` -------------------------------- ### Get Random Locale Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Returns a random locale string. The function signature is `randomLocale(): string`. ```APIDOC randomLocale():string; Returns a random locale. Returns: `string` ``` -------------------------------- ### CLI Commands for Kreya Project Management Source: https://kreya.app/docs/release-notes/beta This snippet details the command-line interface commands for managing Kreya projects, including creating new projects and invoking collections. ```CLI add collection invoke command to CLI add create project command ``` -------------------------------- ### Kreya App Bug Fix: Certificate Selector Source: https://kreya.app/docs/release-notes Hides the certificate selector at the project setup dialog when not needed. ```APIDOC Certificate Selector: - Hide certificate selector at the project setup dialog. ``` -------------------------------- ### Get Last Name Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves the last name. This function returns a string representing the last name. ```typescript lastName():string; ``` -------------------------------- ### Kreya CLI Environment Commands Source: https://kreya.app/docs/category/commands Manages environments within the Kreya application, including getting the active environment. ```APIDOC environment get-active Description: Gets the active environment. Usage: kreyac environment get-active [options] Options: --help: Show help for the environment get-active command. environment [other commands] Description: Manages environments. Usage: kreyac environment [command] [options] Commands: get-active: Gets the active environment. ``` -------------------------------- ### Kreya CLI Project Create Arguments Source: https://kreya.app/docs/cli/commands/project/create Details the arguments for the 'project create' command. The 'ProjectPath' argument is required and specifies the directory for the new project. ```APIDOC project create [ProjectPath] Creates a new project. Arguments: ProjectPath `required` Path where the project should be created. ``` -------------------------------- ### Get Job Type Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves the type of the current job. This function returns a string representing the job type. ```typescript jobType():string; ``` -------------------------------- ### replaceNumbers Function Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Replaces symbols within a string with numbers based on a specified format and optional symbol. For example, '###' can be replaced with '283'. ```APIDOC replaceNumbers(format:string,symbol?:string):string; Parameters: - format: The string format. - symbol?: The symbol to search for in format that will be replaced with a number. Returns: - string: The string with symbols replaced by numbers. ``` -------------------------------- ### Importing and Using Path Module Source: https://kreya.app/docs/scripting-and-tests/general Shows how to import the 'path' module and use its 'join' function to construct file paths within Kreya scripts. ```javascript import{ join }from"path"; const grpcOperationPath =join("../","gRPC","my-operation"); ``` -------------------------------- ### Kreya CLI Project Create Command Source: https://kreya.app/docs/cli/commands/project/create This snippet shows the basic syntax for creating a new project using the Kreya CLI. It requires a ProjectPath argument to specify where the project should be created. ```cli kreyac project create [ProjectPath] ``` -------------------------------- ### Core Bug Fixes (1.11.1) Source: https://kreya.app/docs/release-notes Addresses a critical bug in core functionality related to loading dependencies, preventing startup crashes on new macOS installations. ```English Core: correctly load dependencies to prevent crashes on startup for new MacOS installations ``` -------------------------------- ### productName() - Get Random Product Name Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves a random product name. This function is part of the general Kreya Base Script API. ```typescript productName():string; ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Fixes early scripting messages not showing up when sending a collection. * Ensures that messages logged early in the collection execution process are visible. */ function fixEarlyScriptMessages() { // Logic to ensure early script messages are displayed console.log('Early scripting messages now visible during collection runs.'); } ``` -------------------------------- ### Get City Suffix - Kreya Script API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves a random city suffix. This function is part of the Kreya Base Script API. ```typescript citySuffix():string; Returns: string - A random city suffix. ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Further improves Postman translations. * Addresses remaining issues and enhances the accuracy of Postman script translations. */ function improvePostmanTranslations() { // Refinements to Postman script translation logic console.log('Postman translations further improved.'); } ``` -------------------------------- ### Get County Name - Kreya Script API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves a random county name. This function is part of the Kreya Base Script API. ```typescript county():string; Returns: string - A random county. ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Ensures that all paths used within the application are relative. * This improves portability and avoids issues with hardcoded absolute paths. */ function useRelativePaths() { // Logic to convert absolute paths to relative paths console.log('Using relative paths throughout the application.'); } ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Implements a user variables editor. * Provides an interface for users to manage their custom variables. */ function userVariablesEditor() { // UI and logic for the user variables editor console.log('User variables editor implemented.'); } ``` -------------------------------- ### Get City Name - Kreya Script API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves a random city name. This function is part of the Kreya Base Script API. ```typescript city():string; Returns: string - A random city name. ``` -------------------------------- ### Get City Prefix - Kreya Script API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves a random city prefix. This function is part of the Kreya Base Script API. ```typescript cityPrefix():string; Returns: string - A random city prefix. ``` -------------------------------- ### Core Features (1.10.0) Source: https://kreya.app/docs/release-notes Introduces several core features including a Command Line Interface (CLI), operation history, and options to reset inherited authorization and client certificates, trim prefixes, add static authorization headers, and allow simultaneous operation invocation. Also includes a rework of 'reset requests' to 'reset operation'. ```English Core: add CLI Core: add history for operations Core: add option to reset inherited auth to none Core: add option to reset inherited client certificate to none Core: add option to trim prefix when creating operations from importers Core: add static authorization header value provider Core: allow simultaneous invocation of operations Core: rework 'reset requests' to 'reset operation' ``` -------------------------------- ### Kreya App Feature: Automatic Environment Selection Source: https://kreya.app/docs/release-notes Automatically selects the first environment upon project load. ```APIDOC Automatic Environment Selection: - Select first environment automatically. ``` -------------------------------- ### Get Country Name - Kreya Script API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves a random country name. This function is part of the Kreya Base Script API. ```typescript country():string; Returns: string - A random country. ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Correctly handles arrays in the scripting environment. * Ensures that array operations (like iteration, mapping, filtering) work as expected. */ function handleArraysInScripting() { // Logic for robust array handling in scripts console.log('Array handling in scripting improved.'); } ``` -------------------------------- ### Get Active Environment Source: https://kreya.app/docs/cli/commands/environment/get-active Retrieves the currently active environment within a Kreya project. This command is useful for scripting and automation to determine the active environment. ```bash kreyac environment get-active ``` ```bash kreyac environment get-active -p ./my-project.krproj ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * @typedef {Object} AuthDetails * @property {string} type - The type of authentication (e.g., 'bearer', 'basic'). * @property {Object} credentials - The authentication credentials. */ /** * @typedef {Object} Operation * @property {string} name - The name of the operation. * @property {AuthDetails} authentication - The authentication details for the operation. */ /** * Saves authentication details when switching tabs. * @param {Operation} operation - The operation whose auth details are being saved. */ function saveAuthDetails(operation) { // Implementation to save auth details... console.log(`Saving auth details for: ${operation.name}`); } ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Adds support for JWT authentication provider and option to set header value prefix. * Allows configuration of JWT tokens and their corresponding header prefixes. */ function addJwtAuthProvider() { // Implementation for JWT auth provider and prefix setting console.log('JWT auth provider and header prefix option added.'); } ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Handles invalid directory characters during Postman and Insomnia imports. * Ensures that imports succeed even if directory names contain problematic characters. */ function handleInvalidDirectoryChars() { // Logic to sanitize directory names during import console.log('Handling of invalid directory characters improved.'); } ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Cancels operation collection runs when closing the tab. * Ensures that ongoing operations are properly terminated when a tab is closed. */ function cancelRunOnTabClose() { // Implementation to cancel runs when tabs are closed console.log('Operation runs are now cancelled when tabs are closed.'); } ``` -------------------------------- ### Core Bug Fixes Source: https://kreya.app/docs/release-notes/beta Addresses critical issues in the core functionality, including dependency loading for new macOS installations and handling of operation settings. ```core * **Core:** correctly load dependencies to prevent crashes on startup for new MacOS installations * **Core:** add option to purge user variables * **Core:** add tour for new users * **Core:** build linux arm * **Core:** linux arm snapcraft support * **Core:** about window can now be opened during fullscreen on macos * **Core:** correct windows installation path * **Core:** correctly reevaluate inherited, templated operation settings * **Core:** delete of operations and directories with unsaved changes * **Core:** do not try to store relative paths for resources on a different drive * **Core:** improve Windows installer and WebView2 detection * **Core:** resolve scripting type definitions correctly when switching operation tabs * **Core:** show error details in the ui for well known exceptions * **Core:** add removable-media snapcraft plug * **Core:** correctly handle operation invocation failures * **Core:** oauth refresh token support * **Core:** specify correct linux dependency versions * **Core:** fix account login on snapcraft linux installations * **Core:** macOS icon size and add corner radius * **Core:** add CLI * **Core:** add history for operations * **Core:** add option to reset inherited auth to none * **Core:** add option to reset inherited client certificate to none * **Core:** add option to trim prefix when creating operations from importers * **Core:** add static authorization header value provider * **Core:** allow simultaneous invocation of operations * **Core:** rework 'reset requests' to 'reset operation' * **Core:** correctly apply default settings for environments * **Core:** correctly open project when an absolute path is provided * **Core:** curl clipboard importer use post http method if any data flag is set * **Core:** enhance debug infos in about window * **Core:** if one importer fails, other importers should still run * **Core:** merge environment data and user data correctly * **Core:** resolve blank screen bug * **Core:** save changes when another tab is opened * **Core:** add variable support for scripting and templating ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Fixes the Postman import process for API key authentication. * Ensures that API keys are correctly parsed and applied during import. */ function fixPostmanApiKeyImport() { // Implementation to correct API key import from Postman console.log('Postman API key import fixed.'); } ``` -------------------------------- ### Show Version Information Source: https://kreya.app/docs/cli/commands/version The 'version' command is used to display the current version of the Kreya CLI. This is a fundamental command for checking the installed version and ensuring compatibility. ```cli kreyac version ``` -------------------------------- ### Kreya App Bug Fix: Linux Startup Exception Source: https://kreya.app/docs/release-notes Fixes a rare exception that occurred on startup on Linux systems. ```APIDOC Linux Startup Exception: - Linux: fixed rare exception on startup. ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Automatically translates most Postman scripts during import. * Simplifies the migration of Postman collections by converting scripts. */ function autoTranslatePostmanScripts() { // Logic for automatic translation of Postman scripts console.log('Automatic Postman script translation enabled.'); } ``` -------------------------------- ### Adjusting Kreya Log Settings Source: https://kreya.app/docs/logs Explains how to modify Kreya's logging behavior by referring to the Configuration Guide, which involves updating configuration files or setting environment variables. ```APIDOC Adjusting Log Settings: Refer to the [Configuration Guide](https://kreya.app/docs/configuration/) to modify Kreya's logging settings. This can be done by updating the configuration file or setting environment variables. ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Improves the process of importing scripts with type dependencies. * Ensures that type resolution for script imports is more robust. */ function improveScriptTypeImports() { // Enhancements to script type import resolution console.log('Script type imports improved.'); } ``` -------------------------------- ### Get Country Code - Kreya Script API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Retrieves a random ISO 3166-1 country code. This function is part of the Kreya Base Script API. ```typescript countryCode():string; Returns: string - A random country code. ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Correctly writes Scripts of imported operations to separate files. * Ensures that script content is saved in dedicated files for better organization. */ function writeScriptsToSeparateFiles() { // Logic for saving scripts to individual files console.log('Operation scripts are now correctly saved to separate files.'); } ``` -------------------------------- ### User Variables Management Source: https://kreya.app/docs/scripting-and-tests Demonstrates how to set and get user variables within Kreya scripts for sharing data between operations. User variables can also be accessed via templating. ```javascript In some script kreya.variables.set('my_var', 123); // In some other script const myVar = kreya.variables.get('my_var'); // Or via templating in an operation {{ vars.my_var }} ``` -------------------------------- ### CLI Support for Response/Flag Files Source: https://kreya.app/docs/release-notes Adds support for providing CLI arguments via response or flag files using the @-syntax. This allows for more complex command-line configurations to be managed in external files. ```plaintext CLI: add support for CLI response / flag files (arguments provided in a file with the @-syntax) ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Fixes release deployments. * Addresses issues related to the deployment process for new releases. */ function fixReleaseDeployments() { // Implementation to fix release deployment issues console.log('Release deployments fixed.'); } ``` -------------------------------- ### UserVariablesScriptApi API Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Manages custom user variables, allowing for setting, getting, deleting, and checking the existence of variables. These variables are accessible across operations and via templating. ```APIDOC UserVariablesScriptApi: typeUserVariablesScriptApi={ delete:void; get:any; has:boolean; keys: Iterable; set:void; }; The storage to set and retrieve custom variables, which are accessible in other operations and via templating. Methods: delete(key:string):void; Deletes the specified variable. ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Reorders the operation list after renaming an item. * Maintains the correct order of operations in the UI after renaming. */ function reorderOperationListOnRename() { // Logic to update the operation list order after renaming console.log('Operation list reordering after rename fixed.'); } ``` -------------------------------- ### FakerMusic API Documentation Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Documentation for the FakerMusic API, which provides methods for generating music-related data. It includes properties like locale and randomizer, and methods to get music genres. ```APIDOC FakerMusic: typeFakerMusic = { locale: string; random: FakerRandomizer; genre: string; }; Properties: locale: string; random: FakerRandomizer; Methods: genre(): string; Description: Get a music genre Returns: string ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Prevents showing an operation as sending when it was aborted due to Script errors. * Ensures accurate status reporting for operations that fail due to script exceptions. */ function preventSendStatusOnScriptAbort() { // Logic to update operation status based on script errors console.log('Operation send status correctly reflects script aborts.'); } ``` -------------------------------- ### REST Script API Example Source: https://kreya.app/docs/scripting-and-tests/operation-scripts/rest-script-api-reference Demonstrates how to use the `kreyaRest.onCallCompleted` function to perform assertions on a completed REST call, checking status codes, content types, and response content. ```javascript import{ expect }from'chai'; kreyaRest.onCallCompleted(call=>{ kreya.trace('The REST call completed.'); kreya.test('Status code',()=>expect(call.status.code).to.equal(200)); kreya.test('status is success',()=>expect(call.status.isSuccess).to.be.true); kreya.test('Content type',()=>expect(call.response.contentType).to.eq('application/json')); const curlyBraceCharCode ='{'.charCodeAt(0); kreya.test('Byte content first entry should be a curly brace',()=>expect(call.response.rawContentBytes[0]).to.eq(curlyBraceCharCode)); kreya.test('Text content first char should be a curly brace',()=>expect(call.response.rawContentText[0]).to.eq('{')); kreya.test('Deserialized number should equal',()=>expect(call.response.content.myInt).to.eq(26)); }); ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Sets the multipart request content type correctly and removes the requirement for it. * Ensures correct Content-Type headers for multipart requests and makes it optional. */ function setMultipartRequestContentType() { // Logic to correctly set and optionally omit multipart Content-Type console.log('Multipart request content type handling improved.'); } ``` -------------------------------- ### Define Tests with kreya.test Source: https://kreya.app/docs/scripting-and-tests Demonstrates how to define tests in Kreya scripts using the `kreya.test` function. It utilizes the `chai` assertion library for making assertions. Examples include a failing test and a succeeding test. ```javascript import { expect } from 'chai'; // chai is bundled with Kreya kreya.test('test that will fail', () => expect(2).to.eql(3)); kreya.test('test that will succeed', () => expect(6).to.eql(6)); ``` -------------------------------- ### REST Request Content Type Source: https://kreya.app/docs/operations/rest Explains how to change the request content type for REST operations. Kreya generates example requests based on OpenAPI definitions or defaults to empty if none are found. ```APIDOC APIDOC: Request Content Type: - Click on the request content type tab to change it. - Kreya generates example requests based on OpenAPI definitions. - If no request definition is found, the default request content is empty. ``` -------------------------------- ### Kreya CLI info command with project path Source: https://kreya.app/docs/cli/commands/info Prints information about the Kreya application and the project, specifying the project file path. This allows targeting a specific Kreya project file. ```bash kreyac kreyac info -p ./my-project.krproj ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Adds a file exclusion list for gRPC proto file importers. * Allows users to specify files or patterns to exclude during gRPC proto import. */ function addGrpcFileExclusionList() { // Implementation for gRPC proto file exclusion list console.log('gRPC proto file exclusion list added.'); } ``` -------------------------------- ### FakerLorem Methods Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Provides methods for generating various types of lorem ipsum text. Includes functions to get single letters, multiple lines, paragraphs, sentences, and words, with options for customization. ```typescript letter(num?: number): string; lines(lineCount?: number, separator?: string): string; paragraph(min?: number): string; ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Adds AWS signature version 4 support. * Enables authentication with AWS services using Signature Version 4. */ function addAwsSignatureV4() { // Implementation for AWS Signature Version 4 authentication console.log('AWS Signature Version 4 support added.'); } ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Fixes the Windows installer. * Addresses issues related to the installation process on Windows. */ function fixWindowsInstaller() { // Implementation to resolve Windows installer problems console.log('Windows installer fixed.'); } ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```ui /** * Adds search functionality for operations, directories, and collections. * Improves discoverability of items within the project. */ function addSearchFunctionality() { // UI implementation for search input and results console.log('Search for operations, directories, and collections added.'); } ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Adds request Content-Type header in Postman importer if not already present. * Ensures that Content-Type headers are correctly set during Postman imports. */ function addContentTypeHeaderInPostmanImport() { // Logic to add missing Content-Type headers during Postman import console.log('Content-Type header added during Postman import if missing.'); } ``` -------------------------------- ### Kreya Base Script API - Variable Management Source: https://kreya.app/docs/scripting-and-tests/general/kreya-base-script-api Provides functions to manage variables within the Kreya environment. This includes getting, checking for existence, listing all keys, and setting variables. The 'set' function can also be used to delete a variable by setting its value to undefined. ```APIDOC get(key:string):any; - Gets the value of a variable. - Parameters: - key: The key of the variable (string). - Returns: - any: The value of the variable or undefined if the variable does not exist. has(key:string):boolean; - Checks whether the specified variable exists. - Parameters: - key: The key of the variable (string). - Returns: - boolean: True when the variable exists, otherwise false. keys(): Iterable; - Returns the keys of all stored variables. - Returns: - Iterable: The keys of all stored variables. set(key:string, value:any):void; - Sets a variable. Setting undefined as a value deletes the variable. - Parameters: - key: The key of the variable (string). - value: The value of the variable (any). ``` -------------------------------- ### Untitled Source: https://kreya.app/docs/release-notes/beta No description ```core /** * Fixes a rare crash on macOS when authenticating with OIDC. * This involves ensuring proper handling of security contexts and token exchanges. */ function fixOidcCrashOnMac() { // Implementation details for OIDC authentication fix on macOS console.log('OIDC authentication crash fix applied for macOS.'); } ```