Skip to main content

Write custom AI-enabled codebase automations in Python. Leverage a full codebase-aware API. Automatically trigger automations from Github, Slack, and other providers.

Project description

Blocks SDK

Write custom AI-enabled codebase automations in Python. Leverage a full codebase-aware API. Automatically trigger automations from Github, Slack, and other providers.

We're currently in private alpha, we recommend consistently updating your SDK to the latest version to get the latest features and fixes.

Getting Started

1. Install SDK

pip install blocks-sdk

2. Create a new Blocks project

mkdir -p .blocks/myautomation
cd .blocks/myautomation

3. Create a new automation

# automation.py
from blocks import task, on

@task(name="my_automation")
@on("github.pull_request", repos=["MyOrg/MyRepo"])
def my_automation(event):
    print(event)

5. Upload your automation

blocks init --api-key <your-api-key>
blocks push automation.py

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

blocks_sdk-0.1.97.tar.gz (52.9 kB view details)

Uploaded Source

File details

Details for the file blocks_sdk-0.1.97.tar.gz.

File metadata

  • Download URL: blocks_sdk-0.1.97.tar.gz
  • Upload date:
  • Size: 52.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.11

File hashes

Hashes for blocks_sdk-0.1.97.tar.gz
Algorithm Hash digest
SHA256 e35bcf085357868b7ad67a40c0d2a20bea290c3d2a59d994a724f30dd56b1efe
MD5 3e72803dcee344646e8149bc6e9033ee
BLAKE2b-256 64d8f867ac30b7b9b60a0403e5a9a74afb62a63f181e12c96901e8ce6e7487a3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page