Skip to content
package

GitHub Action

CodeScanAI Action

v1.0.0 Latest version

CodeScanAI Action

package

CodeScanAI Action

A Github action that provides the CodeScanAI project to be used in Github workflows across multiple operating systems

Installation

Copy and paste the following snippet into your .yml file.

              

- name: CodeScanAI Action

uses: codescan-ai/codescanai-action@v1.0.0

Learn more about this action in codescan-ai/codescanai-action

Choose a version

CodeScanAI Action

The action wraps the codescan-ai project that helps scan your codebase for bad coding practices and potential security vulnerabilty.

Inputs

name description required default
version

Version of CodeScanAI to install

false latest
provider

AI provider to use

true ""
model

AI model from the provider to use

false ""
directory

Directory to scan

false .
changes_only

Scans only files with recent changes

false false
repo

GitHub repository

false ""
pr_number

Pull request number

false ""
github_token

GitHub API token

false ""
host

Custom AI server host

false ""
port

Custom AI server port

false ""
token

Token for authenticating with the custom AI server

false ""
endpoint

API endpoint for the custom server

false /api/v1/scan
output_file

Optional output file to store CodeScanAI results

false ""

Runs

This action is a composite action.

Usage

- uses: codescanai/codescanai-action@v1.0.0
  with:
    version:
    # Version of CodeScanAI to install
    #
    # Required: false
    # Default: latest

    provider:
    # AI provider to use
    #
    # Required: true
    # Default: ""

    model:
    # AI model from the provider to use
    #
    # Required: false
    # Default: ""

    directory:
    # Directory to scan
    #
    # Required: false
    # Default: .

    changes_only:
    # Scans only files with recent changes
    #
    # Required: false
    # Default: false

    repo:
    # GitHub repository
    #
    # Required: false
    # Default: ""

    pr_number:
    # Pull request number
    #
    # Required: false
    # Default: ""

    github_token:
    # GitHub API token
    #
    # Required: false
    # Default: ""

    host:
    # Custom AI server host
    #
    # Required: false
    # Default: ""

    port:
    # Custom AI server port
    #
    # Required: false
    # Default: ""

    token:
    # Token for authenticating with the custom AI server
    #
    # Required: false
    # Default: ""

    endpoint:
    # API endpoint for the custom server
    #
    # Required: false
    # Default: /api/v1/scan

    output_file:
    # Optional output file to store CodeScanAI results
    #
    # Required: false
    # Default: ""