Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 41 additions & 27 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,17 @@

### Prerequisites

1. **Install Python 3.13**:
- Download and install Python 3.13 from the official [Python website](https://www.python.org/downloads/)
1. **Install Python ≥ 3.10**:
- Download and install Python 3.10 from the official [Python website](https://www.python.org/downloads/)
- Verify the installation by running:
```sh
python3.13 --version
python3.10 --version
```

Alternative: [mise](https://mise.jdx.dev/lang/python.html)

2. **Install [uv](https://docs.astral.sh/uv/)**:
```sh
pip install uv
```
Follow the official installation instructions for your operating system.

3. **Create a virtual environment in the current working directory**:
```sh
Expand All @@ -25,45 +23,61 @@

4. **Install dependencies**:
```sh
uv sync --all-extras
uv sync --all-extras --no-cache
```

For additional commands related to linting, formatting, and building, run `just --list`.

### Using the SDK Locally

1. Create a project directory:
```sh
mkdir project
cd project
```

See `just --list` for linting, formatting and build commands.
2. Initialize the Python project:
```sh
uv init . --python 3.10
```

3. Set the SDK path:
```sh
PATH_TO_SDK=/Users/YOUR_USERNAME/uipath-python
```

### Use SDK Locally
1. Create a folder on your own device `mkdir project; cd project`
2. Initialize the python project `uv` `uv init . --python 3.9`
3. Obtain the project path `PATH_TO_SDK=/Users/YOU_USER/uipath-python`
4. Install the sdk in editable mode `uv add --editable ${PATH_TO_SDK}`
4. Install the SDK in editable mode:
```sh
uv add --editable ${PATH_TO_SDK}
```

:information_source: Instead of cloning the project into `.venv/lib/python3.9/site-packages/uipath`, this mode creates a file named `_uipath.pth` inside `.venv/lib/python3.9/site-packages`. This file contains the value of `PATH_TO_SDK`, which is added to `sys.path`—the list of directories where python searches for packages. (Run `python -c 'import sys; print(sys.path)'` to see the entries.)
> **Note:** Instead of cloning the project into `.venv/lib/python3.10/site-packages/uipath`, this mode creates a file named `_uipath.pth` inside `.venv/lib/python3.10/site-packages`. This file contains the value of `PATH_TO_SDK`, which is added to `sys.path`—the list of directories where Python searches for packages. To view the entries, run `python -c 'import sys; print(sys.path)'`.

## API Style Guide

### General Rule:
- use key instead of ID
### General Rule
- Use `key` instead of `id` for resource identifiers

### Standard Methods & Naming Conventions
### Standard Methods and Naming Conventions

#### Retrieve a Single Resource
- **Method Name:** `retrieve` instead of get
- **Usage:** To obtain a specific resource instance using its unique identifier (using *key* instead of ID).
- **Extended:**
- `retrieve_by_[field_name]` (for fields other than key)
- **Method Name:** `retrieve`
- **Purpose:** Obtain a specific resource instance using its unique identifier (using `key` instead of `id`)
- **Variations:**
- `retrieve_by_[field_name]` (for fields other than `key`)

#### List Multiple Resources
- **Method Name:** `list`
- **Usage:** To fetch a collection of resources, optionally filtered by query parameters.
- **Purpose:** Fetch a collection of resources, optionally filtered by query parameters
- **Example:**
```python
resources = Resource.list(filters={})
```
```python
resources = Resource.list(filters={})
```

#### Create a Resource
- **Method Name:** `create`
- **Usage:** To add a new resource to the system.
- **Purpose:** Add a new resource to the system

#### Update a Resource
- **Method Name:** `update`
- **Usage:** To modify an existing resource.
- **Purpose:** Modify an existing resource
80 changes: 46 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,29 @@
[![PyPI - Version](https://img.shields.io/pypi/v/uipath)](https://img.shields.io/pypi/v/uipath)
[![Python versions](https://img.shields.io/pypi/pyversions/uipath.svg)](https://pypi.org/project/uipath/)


A Python SDK that enables programmatic interaction with UiPath Platform services including processes, assets, buckets, context grounding, data services, jobs, and more. The package also features a CLI for creation, packaging, and deployment of automations to UiPath Platform.

Use the [UiPath LangChain SDK](https://github.com/UiPath/uipath-langchain-python) to pack and publish LangGraph Agents.
Use the [UiPath LangChain SDK](https://github.com/UiPath/uipath-langchain-python) to pack and publish LangGraph Agents.

## Table of Contents

- [Installation](#installation)
- [Configuration](#configuration)
- [Environment Variables](#environment-variables)
- [Basic Usage](#basic-usage)
- [Available Services](#available-services)
- [Examples](#examples)
- [Buckets Service](#buckets-service)
- [Context Grounding Service](#context-grounding-service)
- [Command Line Interface (CLI)](#command-line-interface-cli)
- [Authentication](#authentication)
- [Initialize a Project](#initialize-a-project)
- [Debug a Project](#debug-a-project)
- [Package a Project](#package-a-project)
- [Publish a Package](#publish-a-package)
- [Project Structure](#project-structure)
- [Development](#development)
- [Setting Up a Development Environment](#setting-up-a-development-environment)
- [Installation](#installation)
- [Configuration](#configuration)
- [Environment Variables](#environment-variables)
- [Basic Usage](#basic-usage)
- [Available Services](#available-services)
- [Examples](#examples)
- [Buckets Service](#buckets-service)
- [Context Grounding Service](#context-grounding-service)
- [Command Line Interface (CLI)](#command-line-interface-cli)
- [Authentication](#authentication)
- [Initialize a Project](#initialize-a-project)
- [Debug a Project](#debug-a-project)
- [Package a Project](#package-a-project)
- [Publish a Package](#publish-a-package)
- [Project Structure](#project-structure)
- [Development](#development)
- [Setting Up a Development Environment](#setting-up-a-development-environment)

## Installation

Expand Down Expand Up @@ -69,15 +69,24 @@ asset = sdk.assets.retrieve(name="MyAsset")
## Available Services

The SDK provides access to various UiPath services:
- `sdk.processes` - Manage and execute UiPath automation processes
- `sdk.assets` - Work with assets (variables, credentials) stored in UiPath
- `sdk.buckets` - Manage cloud storage containers for automation files
- `sdk.connections` - Handle connections to external systems
- `sdk.context_grounding` - Work with semantic contexts for AI-enabled automation
- `sdk.jobs` - Monitor and manage automation jobs
- `sdk.queues` - Work with transaction queues
- `sdk.actions` - Work with Action Center
- `sdk.api_client` - Direct access to the API client for custom requests

- `sdk.processes` - Manage and execute UiPath automation processes

- `sdk.assets` - Work with assets (variables, credentials) stored in UiPath

- `sdk.buckets` - Manage cloud storage containers for automation files

- `sdk.connections` - Handle connections to external systems

- `sdk.context_grounding` - Work with semantic contexts for AI-enabled automation

- `sdk.jobs` - Monitor and manage automation jobs

- `sdk.queues` - Work with transaction queues

- `sdk.actions` - Work with Action Center

- `sdk.api_client` - Direct access to the API client for custom requests

## Examples

Expand Down Expand Up @@ -140,10 +149,12 @@ uipath pack
Packages your project into a `.nupkg` file that can be deployed to UiPath.

**Note:** Your `pyproject.toml` must include:
- A description field (avoid characters: &, <, >, ", ', ;)
- Author information

- A description field (avoid characters: &, <, >, ", ', ;)
- Author information

Example:

```toml
description = "Your package description"
authors = [{name = "Your Name", email = "your.email@example.com"}]
Expand All @@ -160,12 +171,13 @@ Publishes the most recently created package to your UiPath Orchestrator.
## Project Structure

To properly use the CLI for packaging and publishing, your project should include:
- A `pyproject.toml` file with project metadata
- A `uipath.json` file (generated by `uipath init`)
- Any Python files needed for your automation

- A `pyproject.toml` file with project metadata
- A `uipath.json` file (generated by `uipath init`)
- Any Python files needed for your automation

## Development

### Setting Up a Development Environment

Please read our [contribution guidelines](CONTRIBUTING.md) before submitting a pull request.
Please read [CONTRIBUTING.md](https://uipath.github.io/uipath-python/how_to_contribute/) before submitting a pull request.
Loading