mirror of
https://github.com/block/goose.git
synced 2026-07-17 12:56:20 +02:00
40 lines
801 B
Python
40 lines
801 B
Python
# coding: utf-8
|
|
|
|
"""
|
|
goose-server
|
|
|
|
An AI agent
|
|
|
|
The version of the OpenAPI document: 1.9.0
|
|
Contact: ai-oss-tools@block.xyz
|
|
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
|
|
Do not edit the class manually.
|
|
""" # noqa: E501
|
|
|
|
|
|
from __future__ import annotations
|
|
import json
|
|
from enum import Enum
|
|
from typing_extensions import Self
|
|
|
|
|
|
class PermissionLevel(str, Enum):
|
|
"""
|
|
Enum representing the possible permission levels for a tool.
|
|
"""
|
|
|
|
"""
|
|
allowed enum values
|
|
"""
|
|
ALWAYS_ALLOW = 'always_allow'
|
|
ASK_BEFORE = 'ask_before'
|
|
NEVER_ALLOW = 'never_allow'
|
|
|
|
@classmethod
|
|
def from_json(cls, json_str: str) -> Self:
|
|
"""Create an instance of PermissionLevel from a JSON string"""
|
|
return cls(json.loads(json_str))
|
|
|
|
|