mirror of
https://github.com/lightninglabs/lightning-terminal.git
synced 2026-08-16 13:01:14 +02:00
This commit introduces a comprehensive Starlark scripting system that enables custom automation with access to all subdaemon RPCs (lnd, loop, pool, faraday, taproot-assets). Scripts use native LND macaroons for permission enforcement. Key features: - Starlark execution engine with sandboxed resource limits - Standard builtins: print, log, sleep, now, json_encode/decode - HTTP GET requests with URL allowlisting - Persistent KV store with bucket-based permissions - LND event subscriptions for long-running daemon scripts - Script CRUD operations with macaroon baking - Execution history and running script tracking - Complete CLI commands (litcli scripts ...) Database schema: - scripts: Store script definitions with macaroon permissions - script_executions: Audit trail for script runs - script_kv_store: Persistent key-value storage for scripts - running_scripts: Track currently running scripts Security model: - Each script has an LND macaroon baked with specific permissions - RPC calls from scripts include this macaroon in the header - LND/subdaemons validate permissions natively - URL and bucket allowlists validated at runtime
2050 lines
62 KiB
Go
2050 lines
62 KiB
Go
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
// versions:
|
|
// protoc-gen-go v1.36.11
|
|
// protoc v3.12.4
|
|
// source: lit-scripts.proto
|
|
|
|
package litrpc
|
|
|
|
import (
|
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
reflect "reflect"
|
|
sync "sync"
|
|
unsafe "unsafe"
|
|
)
|
|
|
|
const (
|
|
// Verify that this generated code is sufficiently up-to-date.
|
|
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
)
|
|
|
|
// Script represents a Starlark script with its configuration.
|
|
type Script struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The unique name of the script.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
// An optional description of what the script does.
|
|
Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
|
|
// The Starlark source code.
|
|
Source string `protobuf:"bytes,3,opt,name=source,proto3" json:"source,omitempty"`
|
|
// The permissions that were used to bake the script's macaroon.
|
|
Permissions []*MacaroonPermission `protobuf:"bytes,4,rep,name=permissions,proto3" json:"permissions,omitempty"`
|
|
// Timeout in seconds for script execution. 0 means no timeout (for
|
|
// long-running scripts that use subscriptions).
|
|
TimeoutSecs uint32 `protobuf:"varint,5,opt,name=timeout_secs,json=timeoutSecs,proto3" json:"timeout_secs,omitempty"`
|
|
// Maximum memory in bytes the script can use.
|
|
MaxMemoryBytes uint64 `protobuf:"varint,6,opt,name=max_memory_bytes,json=maxMemoryBytes,proto3" json:"max_memory_bytes,omitempty"`
|
|
// URL patterns that the script is allowed to access via http_get.
|
|
// Supports glob patterns like "https://api.example.com/".
|
|
AllowedUrls []string `protobuf:"bytes,7,rep,name=allowed_urls,json=allowedUrls,proto3" json:"allowed_urls,omitempty"`
|
|
// KV bucket names the script can access in addition to its own default
|
|
// bucket (which has the same name as the script).
|
|
AllowedBuckets []string `protobuf:"bytes,8,rep,name=allowed_buckets,json=allowedBuckets,proto3" json:"allowed_buckets,omitempty"`
|
|
// Unix timestamp when the script was created.
|
|
CreatedAt uint64 `protobuf:"varint,9,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
|
|
// Unix timestamp when the script was last updated.
|
|
UpdatedAt uint64 `protobuf:"varint,10,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
|
|
// Whether the script is currently running.
|
|
IsRunning bool `protobuf:"varint,11,opt,name=is_running,json=isRunning,proto3" json:"is_running,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *Script) Reset() {
|
|
*x = Script{}
|
|
mi := &file_lit_scripts_proto_msgTypes[0]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *Script) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*Script) ProtoMessage() {}
|
|
|
|
func (x *Script) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[0]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use Script.ProtoReflect.Descriptor instead.
|
|
func (*Script) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{0}
|
|
}
|
|
|
|
func (x *Script) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Script) GetDescription() string {
|
|
if x != nil {
|
|
return x.Description
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Script) GetSource() string {
|
|
if x != nil {
|
|
return x.Source
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Script) GetPermissions() []*MacaroonPermission {
|
|
if x != nil {
|
|
return x.Permissions
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *Script) GetTimeoutSecs() uint32 {
|
|
if x != nil {
|
|
return x.TimeoutSecs
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Script) GetMaxMemoryBytes() uint64 {
|
|
if x != nil {
|
|
return x.MaxMemoryBytes
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Script) GetAllowedUrls() []string {
|
|
if x != nil {
|
|
return x.AllowedUrls
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *Script) GetAllowedBuckets() []string {
|
|
if x != nil {
|
|
return x.AllowedBuckets
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *Script) GetCreatedAt() uint64 {
|
|
if x != nil {
|
|
return x.CreatedAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Script) GetUpdatedAt() uint64 {
|
|
if x != nil {
|
|
return x.UpdatedAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Script) GetIsRunning() bool {
|
|
if x != nil {
|
|
return x.IsRunning
|
|
}
|
|
return false
|
|
}
|
|
|
|
// CreateScriptRequest is used to create a new script.
|
|
type CreateScriptRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The unique name for the script.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
// An optional description of what the script does.
|
|
Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
|
|
// The Starlark source code.
|
|
Source string `protobuf:"bytes,3,opt,name=source,proto3" json:"source,omitempty"`
|
|
// The permissions to bake into the script's macaroon. These determine what
|
|
// RPCs the script can call.
|
|
Permissions []*MacaroonPermission `protobuf:"bytes,4,rep,name=permissions,proto3" json:"permissions,omitempty"`
|
|
// Timeout in seconds for script execution. 0 means no timeout.
|
|
TimeoutSecs uint32 `protobuf:"varint,5,opt,name=timeout_secs,json=timeoutSecs,proto3" json:"timeout_secs,omitempty"`
|
|
// Maximum memory in bytes the script can use. Defaults to 100MB if not set.
|
|
MaxMemoryBytes uint64 `protobuf:"varint,6,opt,name=max_memory_bytes,json=maxMemoryBytes,proto3" json:"max_memory_bytes,omitempty"`
|
|
// URL patterns that the script is allowed to access via http_get.
|
|
AllowedUrls []string `protobuf:"bytes,7,rep,name=allowed_urls,json=allowedUrls,proto3" json:"allowed_urls,omitempty"`
|
|
// KV bucket names the script can access beyond its own default bucket.
|
|
AllowedBuckets []string `protobuf:"bytes,8,rep,name=allowed_buckets,json=allowedBuckets,proto3" json:"allowed_buckets,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *CreateScriptRequest) Reset() {
|
|
*x = CreateScriptRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[1]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *CreateScriptRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CreateScriptRequest) ProtoMessage() {}
|
|
|
|
func (x *CreateScriptRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[1]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use CreateScriptRequest.ProtoReflect.Descriptor instead.
|
|
func (*CreateScriptRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{1}
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetDescription() string {
|
|
if x != nil {
|
|
return x.Description
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetSource() string {
|
|
if x != nil {
|
|
return x.Source
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetPermissions() []*MacaroonPermission {
|
|
if x != nil {
|
|
return x.Permissions
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetTimeoutSecs() uint32 {
|
|
if x != nil {
|
|
return x.TimeoutSecs
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetMaxMemoryBytes() uint64 {
|
|
if x != nil {
|
|
return x.MaxMemoryBytes
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetAllowedUrls() []string {
|
|
if x != nil {
|
|
return x.AllowedUrls
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *CreateScriptRequest) GetAllowedBuckets() []string {
|
|
if x != nil {
|
|
return x.AllowedBuckets
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type CreateScriptResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The created script.
|
|
Script *Script `protobuf:"bytes,1,opt,name=script,proto3" json:"script,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *CreateScriptResponse) Reset() {
|
|
*x = CreateScriptResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[2]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *CreateScriptResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CreateScriptResponse) ProtoMessage() {}
|
|
|
|
func (x *CreateScriptResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[2]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use CreateScriptResponse.ProtoReflect.Descriptor instead.
|
|
func (*CreateScriptResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{2}
|
|
}
|
|
|
|
func (x *CreateScriptResponse) GetScript() *Script {
|
|
if x != nil {
|
|
return x.Script
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type UpdateScriptRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The name of the script to update.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
// The new description. If empty, the existing description is kept.
|
|
Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
|
|
// The new source code. If empty, the existing source is kept.
|
|
Source string `protobuf:"bytes,3,opt,name=source,proto3" json:"source,omitempty"`
|
|
// New permissions. If empty, existing permissions are kept.
|
|
// Note: Changing permissions will bake a new macaroon.
|
|
Permissions []*MacaroonPermission `protobuf:"bytes,4,rep,name=permissions,proto3" json:"permissions,omitempty"`
|
|
// New timeout. Set to 0 to indicate no timeout.
|
|
TimeoutSecs uint32 `protobuf:"varint,5,opt,name=timeout_secs,json=timeoutSecs,proto3" json:"timeout_secs,omitempty"`
|
|
// New memory limit. Set to 0 to keep existing limit.
|
|
MaxMemoryBytes uint64 `protobuf:"varint,6,opt,name=max_memory_bytes,json=maxMemoryBytes,proto3" json:"max_memory_bytes,omitempty"`
|
|
// New URL allowlist. Set to replace existing list.
|
|
AllowedUrls []string `protobuf:"bytes,7,rep,name=allowed_urls,json=allowedUrls,proto3" json:"allowed_urls,omitempty"`
|
|
// New bucket allowlist. Set to replace existing list.
|
|
AllowedBuckets []string `protobuf:"bytes,8,rep,name=allowed_buckets,json=allowedBuckets,proto3" json:"allowed_buckets,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) Reset() {
|
|
*x = UpdateScriptRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[3]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*UpdateScriptRequest) ProtoMessage() {}
|
|
|
|
func (x *UpdateScriptRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[3]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use UpdateScriptRequest.ProtoReflect.Descriptor instead.
|
|
func (*UpdateScriptRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{3}
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetDescription() string {
|
|
if x != nil {
|
|
return x.Description
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetSource() string {
|
|
if x != nil {
|
|
return x.Source
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetPermissions() []*MacaroonPermission {
|
|
if x != nil {
|
|
return x.Permissions
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetTimeoutSecs() uint32 {
|
|
if x != nil {
|
|
return x.TimeoutSecs
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetMaxMemoryBytes() uint64 {
|
|
if x != nil {
|
|
return x.MaxMemoryBytes
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetAllowedUrls() []string {
|
|
if x != nil {
|
|
return x.AllowedUrls
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *UpdateScriptRequest) GetAllowedBuckets() []string {
|
|
if x != nil {
|
|
return x.AllowedBuckets
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type UpdateScriptResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The updated script.
|
|
Script *Script `protobuf:"bytes,1,opt,name=script,proto3" json:"script,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *UpdateScriptResponse) Reset() {
|
|
*x = UpdateScriptResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[4]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *UpdateScriptResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*UpdateScriptResponse) ProtoMessage() {}
|
|
|
|
func (x *UpdateScriptResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[4]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use UpdateScriptResponse.ProtoReflect.Descriptor instead.
|
|
func (*UpdateScriptResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{4}
|
|
}
|
|
|
|
func (x *UpdateScriptResponse) GetScript() *Script {
|
|
if x != nil {
|
|
return x.Script
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type DeleteScriptRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The name of the script to delete.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
// If true, also delete the script's KV bucket data.
|
|
DeleteKvData bool `protobuf:"varint,2,opt,name=delete_kv_data,json=deleteKvData,proto3" json:"delete_kv_data,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *DeleteScriptRequest) Reset() {
|
|
*x = DeleteScriptRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[5]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *DeleteScriptRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*DeleteScriptRequest) ProtoMessage() {}
|
|
|
|
func (x *DeleteScriptRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[5]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use DeleteScriptRequest.ProtoReflect.Descriptor instead.
|
|
func (*DeleteScriptRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{5}
|
|
}
|
|
|
|
func (x *DeleteScriptRequest) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *DeleteScriptRequest) GetDeleteKvData() bool {
|
|
if x != nil {
|
|
return x.DeleteKvData
|
|
}
|
|
return false
|
|
}
|
|
|
|
type DeleteScriptResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *DeleteScriptResponse) Reset() {
|
|
*x = DeleteScriptResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[6]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *DeleteScriptResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*DeleteScriptResponse) ProtoMessage() {}
|
|
|
|
func (x *DeleteScriptResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[6]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use DeleteScriptResponse.ProtoReflect.Descriptor instead.
|
|
func (*DeleteScriptResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{6}
|
|
}
|
|
|
|
type GetScriptRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The name of the script to retrieve.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetScriptRequest) Reset() {
|
|
*x = GetScriptRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[7]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetScriptRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetScriptRequest) ProtoMessage() {}
|
|
|
|
func (x *GetScriptRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[7]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use GetScriptRequest.ProtoReflect.Descriptor instead.
|
|
func (*GetScriptRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{7}
|
|
}
|
|
|
|
func (x *GetScriptRequest) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type GetScriptResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The requested script.
|
|
Script *Script `protobuf:"bytes,1,opt,name=script,proto3" json:"script,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetScriptResponse) Reset() {
|
|
*x = GetScriptResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[8]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetScriptResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetScriptResponse) ProtoMessage() {}
|
|
|
|
func (x *GetScriptResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[8]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use GetScriptResponse.ProtoReflect.Descriptor instead.
|
|
func (*GetScriptResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{8}
|
|
}
|
|
|
|
func (x *GetScriptResponse) GetScript() *Script {
|
|
if x != nil {
|
|
return x.Script
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type ListScriptsRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListScriptsRequest) Reset() {
|
|
*x = ListScriptsRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[9]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListScriptsRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListScriptsRequest) ProtoMessage() {}
|
|
|
|
func (x *ListScriptsRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[9]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ListScriptsRequest.ProtoReflect.Descriptor instead.
|
|
func (*ListScriptsRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{9}
|
|
}
|
|
|
|
type ListScriptsResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// All scripts in the system.
|
|
Scripts []*Script `protobuf:"bytes,1,rep,name=scripts,proto3" json:"scripts,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListScriptsResponse) Reset() {
|
|
*x = ListScriptsResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[10]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListScriptsResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListScriptsResponse) ProtoMessage() {}
|
|
|
|
func (x *ListScriptsResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[10]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ListScriptsResponse.ProtoReflect.Descriptor instead.
|
|
func (*ListScriptsResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{10}
|
|
}
|
|
|
|
func (x *ListScriptsResponse) GetScripts() []*Script {
|
|
if x != nil {
|
|
return x.Scripts
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type StartScriptRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The name of the script to start.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
// Optional JSON-encoded arguments to pass to the script's main function.
|
|
// These will be passed as keyword arguments.
|
|
ArgsJson string `protobuf:"bytes,2,opt,name=args_json,json=argsJson,proto3" json:"args_json,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *StartScriptRequest) Reset() {
|
|
*x = StartScriptRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[11]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *StartScriptRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*StartScriptRequest) ProtoMessage() {}
|
|
|
|
func (x *StartScriptRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[11]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use StartScriptRequest.ProtoReflect.Descriptor instead.
|
|
func (*StartScriptRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{11}
|
|
}
|
|
|
|
func (x *StartScriptRequest) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *StartScriptRequest) GetArgsJson() string {
|
|
if x != nil {
|
|
return x.ArgsJson
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type StartScriptResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The execution ID for this run.
|
|
ExecutionId uint64 `protobuf:"varint,1,opt,name=execution_id,json=executionId,proto3" json:"execution_id,omitempty"`
|
|
// For short-running scripts (with timeout), the result is returned directly.
|
|
// For long-running scripts, this will be empty and status can be checked via
|
|
// ListRunningScripts.
|
|
ResultJson string `protobuf:"bytes,2,opt,name=result_json,json=resultJson,proto3" json:"result_json,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *StartScriptResponse) Reset() {
|
|
*x = StartScriptResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[12]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *StartScriptResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*StartScriptResponse) ProtoMessage() {}
|
|
|
|
func (x *StartScriptResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[12]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use StartScriptResponse.ProtoReflect.Descriptor instead.
|
|
func (*StartScriptResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{12}
|
|
}
|
|
|
|
func (x *StartScriptResponse) GetExecutionId() uint64 {
|
|
if x != nil {
|
|
return x.ExecutionId
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *StartScriptResponse) GetResultJson() string {
|
|
if x != nil {
|
|
return x.ResultJson
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type StopScriptRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The name of the script to stop.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *StopScriptRequest) Reset() {
|
|
*x = StopScriptRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[13]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *StopScriptRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*StopScriptRequest) ProtoMessage() {}
|
|
|
|
func (x *StopScriptRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[13]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use StopScriptRequest.ProtoReflect.Descriptor instead.
|
|
func (*StopScriptRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{13}
|
|
}
|
|
|
|
func (x *StopScriptRequest) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type StopScriptResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *StopScriptResponse) Reset() {
|
|
*x = StopScriptResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[14]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *StopScriptResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*StopScriptResponse) ProtoMessage() {}
|
|
|
|
func (x *StopScriptResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[14]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use StopScriptResponse.ProtoReflect.Descriptor instead.
|
|
func (*StopScriptResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{14}
|
|
}
|
|
|
|
type ListRunningScriptsRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListRunningScriptsRequest) Reset() {
|
|
*x = ListRunningScriptsRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[15]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListRunningScriptsRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListRunningScriptsRequest) ProtoMessage() {}
|
|
|
|
func (x *ListRunningScriptsRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[15]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ListRunningScriptsRequest.ProtoReflect.Descriptor instead.
|
|
func (*ListRunningScriptsRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{15}
|
|
}
|
|
|
|
type ListRunningScriptsResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// Currently running scripts.
|
|
RunningScripts []*RunningScript `protobuf:"bytes,1,rep,name=running_scripts,json=runningScripts,proto3" json:"running_scripts,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListRunningScriptsResponse) Reset() {
|
|
*x = ListRunningScriptsResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[16]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListRunningScriptsResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListRunningScriptsResponse) ProtoMessage() {}
|
|
|
|
func (x *ListRunningScriptsResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[16]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ListRunningScriptsResponse.ProtoReflect.Descriptor instead.
|
|
func (*ListRunningScriptsResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{16}
|
|
}
|
|
|
|
func (x *ListRunningScriptsResponse) GetRunningScripts() []*RunningScript {
|
|
if x != nil {
|
|
return x.RunningScripts
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type RunningScript struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The script name.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
// The execution ID.
|
|
ExecutionId uint64 `protobuf:"varint,2,opt,name=execution_id,json=executionId,proto3" json:"execution_id,omitempty"`
|
|
// Unix timestamp when execution started.
|
|
StartedAt uint64 `protobuf:"varint,3,opt,name=started_at,json=startedAt,proto3" json:"started_at,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *RunningScript) Reset() {
|
|
*x = RunningScript{}
|
|
mi := &file_lit_scripts_proto_msgTypes[17]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *RunningScript) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*RunningScript) ProtoMessage() {}
|
|
|
|
func (x *RunningScript) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[17]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use RunningScript.ProtoReflect.Descriptor instead.
|
|
func (*RunningScript) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{17}
|
|
}
|
|
|
|
func (x *RunningScript) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *RunningScript) GetExecutionId() uint64 {
|
|
if x != nil {
|
|
return x.ExecutionId
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *RunningScript) GetStartedAt() uint64 {
|
|
if x != nil {
|
|
return x.StartedAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type ValidateScriptRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The Starlark source code to validate.
|
|
Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ValidateScriptRequest) Reset() {
|
|
*x = ValidateScriptRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[18]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ValidateScriptRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ValidateScriptRequest) ProtoMessage() {}
|
|
|
|
func (x *ValidateScriptRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[18]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ValidateScriptRequest.ProtoReflect.Descriptor instead.
|
|
func (*ValidateScriptRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{18}
|
|
}
|
|
|
|
func (x *ValidateScriptRequest) GetSource() string {
|
|
if x != nil {
|
|
return x.Source
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type ValidateScriptResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// Whether the script is valid.
|
|
Valid bool `protobuf:"varint,1,opt,name=valid,proto3" json:"valid,omitempty"`
|
|
// If not valid, the error message.
|
|
Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
|
|
// List of warnings (non-fatal issues).
|
|
Warnings []string `protobuf:"bytes,3,rep,name=warnings,proto3" json:"warnings,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ValidateScriptResponse) Reset() {
|
|
*x = ValidateScriptResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[19]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ValidateScriptResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ValidateScriptResponse) ProtoMessage() {}
|
|
|
|
func (x *ValidateScriptResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[19]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ValidateScriptResponse.ProtoReflect.Descriptor instead.
|
|
func (*ValidateScriptResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{19}
|
|
}
|
|
|
|
func (x *ValidateScriptResponse) GetValid() bool {
|
|
if x != nil {
|
|
return x.Valid
|
|
}
|
|
return false
|
|
}
|
|
|
|
func (x *ValidateScriptResponse) GetError() string {
|
|
if x != nil {
|
|
return x.Error
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *ValidateScriptResponse) GetWarnings() []string {
|
|
if x != nil {
|
|
return x.Warnings
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type GetExecutionHistoryRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The script name to get history for. If empty, returns history for all
|
|
// scripts.
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
// Maximum number of executions to return.
|
|
Limit uint32 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"`
|
|
// Offset for pagination.
|
|
Offset uint32 `protobuf:"varint,3,opt,name=offset,proto3" json:"offset,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetExecutionHistoryRequest) Reset() {
|
|
*x = GetExecutionHistoryRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[20]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetExecutionHistoryRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetExecutionHistoryRequest) ProtoMessage() {}
|
|
|
|
func (x *GetExecutionHistoryRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[20]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use GetExecutionHistoryRequest.ProtoReflect.Descriptor instead.
|
|
func (*GetExecutionHistoryRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{20}
|
|
}
|
|
|
|
func (x *GetExecutionHistoryRequest) GetName() string {
|
|
if x != nil {
|
|
return x.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *GetExecutionHistoryRequest) GetLimit() uint32 {
|
|
if x != nil {
|
|
return x.Limit
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *GetExecutionHistoryRequest) GetOffset() uint32 {
|
|
if x != nil {
|
|
return x.Offset
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type GetExecutionHistoryResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The execution history.
|
|
Executions []*ScriptExecution `protobuf:"bytes,1,rep,name=executions,proto3" json:"executions,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetExecutionHistoryResponse) Reset() {
|
|
*x = GetExecutionHistoryResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[21]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetExecutionHistoryResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetExecutionHistoryResponse) ProtoMessage() {}
|
|
|
|
func (x *GetExecutionHistoryResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[21]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use GetExecutionHistoryResponse.ProtoReflect.Descriptor instead.
|
|
func (*GetExecutionHistoryResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{21}
|
|
}
|
|
|
|
func (x *GetExecutionHistoryResponse) GetExecutions() []*ScriptExecution {
|
|
if x != nil {
|
|
return x.Executions
|
|
}
|
|
return nil
|
|
}
|
|
|
|
// ScriptExecution represents a single execution of a script.
|
|
type ScriptExecution struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The execution ID.
|
|
Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
|
|
// The name of the script that was executed.
|
|
ScriptName string `protobuf:"bytes,2,opt,name=script_name,json=scriptName,proto3" json:"script_name,omitempty"`
|
|
// Unix timestamp when execution started.
|
|
StartedAt uint64 `protobuf:"varint,3,opt,name=started_at,json=startedAt,proto3" json:"started_at,omitempty"`
|
|
// Unix timestamp when execution ended. 0 if still running.
|
|
EndedAt uint64 `protobuf:"varint,4,opt,name=ended_at,json=endedAt,proto3" json:"ended_at,omitempty"`
|
|
// The execution state: 'running', 'completed', 'failed', 'stopped'.
|
|
State string `protobuf:"bytes,5,opt,name=state,proto3" json:"state,omitempty"`
|
|
// JSON-encoded result if completed successfully.
|
|
ResultJson string `protobuf:"bytes,6,opt,name=result_json,json=resultJson,proto3" json:"result_json,omitempty"`
|
|
// Error message if the execution failed.
|
|
ErrorMessage string `protobuf:"bytes,7,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"`
|
|
// Duration in milliseconds.
|
|
DurationMs uint64 `protobuf:"varint,8,opt,name=duration_ms,json=durationMs,proto3" json:"duration_ms,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ScriptExecution) Reset() {
|
|
*x = ScriptExecution{}
|
|
mi := &file_lit_scripts_proto_msgTypes[22]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ScriptExecution) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ScriptExecution) ProtoMessage() {}
|
|
|
|
func (x *ScriptExecution) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[22]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ScriptExecution.ProtoReflect.Descriptor instead.
|
|
func (*ScriptExecution) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{22}
|
|
}
|
|
|
|
func (x *ScriptExecution) GetId() uint64 {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *ScriptExecution) GetScriptName() string {
|
|
if x != nil {
|
|
return x.ScriptName
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *ScriptExecution) GetStartedAt() uint64 {
|
|
if x != nil {
|
|
return x.StartedAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *ScriptExecution) GetEndedAt() uint64 {
|
|
if x != nil {
|
|
return x.EndedAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *ScriptExecution) GetState() string {
|
|
if x != nil {
|
|
return x.State
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *ScriptExecution) GetResultJson() string {
|
|
if x != nil {
|
|
return x.ResultJson
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *ScriptExecution) GetErrorMessage() string {
|
|
if x != nil {
|
|
return x.ErrorMessage
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *ScriptExecution) GetDurationMs() uint64 {
|
|
if x != nil {
|
|
return x.DurationMs
|
|
}
|
|
return 0
|
|
}
|
|
|
|
// KVGetRequest retrieves a value from the KV store.
|
|
type KVGetRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The key to retrieve.
|
|
Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
|
|
// The bucket to retrieve from. Defaults to the caller's script name bucket
|
|
// if not specified.
|
|
Bucket string `protobuf:"bytes,2,opt,name=bucket,proto3" json:"bucket,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVGetRequest) Reset() {
|
|
*x = KVGetRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[23]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVGetRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVGetRequest) ProtoMessage() {}
|
|
|
|
func (x *KVGetRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[23]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVGetRequest.ProtoReflect.Descriptor instead.
|
|
func (*KVGetRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{23}
|
|
}
|
|
|
|
func (x *KVGetRequest) GetKey() string {
|
|
if x != nil {
|
|
return x.Key
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *KVGetRequest) GetBucket() string {
|
|
if x != nil {
|
|
return x.Bucket
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type KVGetResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The value, if found.
|
|
Value []byte `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
|
|
// Whether the key was found.
|
|
Found bool `protobuf:"varint,2,opt,name=found,proto3" json:"found,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVGetResponse) Reset() {
|
|
*x = KVGetResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[24]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVGetResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVGetResponse) ProtoMessage() {}
|
|
|
|
func (x *KVGetResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[24]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVGetResponse.ProtoReflect.Descriptor instead.
|
|
func (*KVGetResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{24}
|
|
}
|
|
|
|
func (x *KVGetResponse) GetValue() []byte {
|
|
if x != nil {
|
|
return x.Value
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *KVGetResponse) GetFound() bool {
|
|
if x != nil {
|
|
return x.Found
|
|
}
|
|
return false
|
|
}
|
|
|
|
// KVPutRequest stores a value in the KV store.
|
|
type KVPutRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The key to store.
|
|
Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
|
|
// The value to store.
|
|
Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
|
|
// The bucket to store in. Defaults to the caller's script name bucket
|
|
// if not specified.
|
|
Bucket string `protobuf:"bytes,3,opt,name=bucket,proto3" json:"bucket,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVPutRequest) Reset() {
|
|
*x = KVPutRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[25]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVPutRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVPutRequest) ProtoMessage() {}
|
|
|
|
func (x *KVPutRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[25]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVPutRequest.ProtoReflect.Descriptor instead.
|
|
func (*KVPutRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{25}
|
|
}
|
|
|
|
func (x *KVPutRequest) GetKey() string {
|
|
if x != nil {
|
|
return x.Key
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *KVPutRequest) GetValue() []byte {
|
|
if x != nil {
|
|
return x.Value
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *KVPutRequest) GetBucket() string {
|
|
if x != nil {
|
|
return x.Bucket
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type KVPutResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVPutResponse) Reset() {
|
|
*x = KVPutResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[26]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVPutResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVPutResponse) ProtoMessage() {}
|
|
|
|
func (x *KVPutResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[26]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVPutResponse.ProtoReflect.Descriptor instead.
|
|
func (*KVPutResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{26}
|
|
}
|
|
|
|
// KVDeleteRequest removes a value from the KV store.
|
|
type KVDeleteRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The key to delete.
|
|
Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
|
|
// The bucket to delete from. Defaults to the caller's script name bucket
|
|
// if not specified.
|
|
Bucket string `protobuf:"bytes,2,opt,name=bucket,proto3" json:"bucket,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVDeleteRequest) Reset() {
|
|
*x = KVDeleteRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[27]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVDeleteRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVDeleteRequest) ProtoMessage() {}
|
|
|
|
func (x *KVDeleteRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[27]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVDeleteRequest.ProtoReflect.Descriptor instead.
|
|
func (*KVDeleteRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{27}
|
|
}
|
|
|
|
func (x *KVDeleteRequest) GetKey() string {
|
|
if x != nil {
|
|
return x.Key
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *KVDeleteRequest) GetBucket() string {
|
|
if x != nil {
|
|
return x.Bucket
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type KVDeleteResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVDeleteResponse) Reset() {
|
|
*x = KVDeleteResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[28]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVDeleteResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVDeleteResponse) ProtoMessage() {}
|
|
|
|
func (x *KVDeleteResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[28]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVDeleteResponse.ProtoReflect.Descriptor instead.
|
|
func (*KVDeleteResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{28}
|
|
}
|
|
|
|
// KVListRequest lists keys in a bucket.
|
|
type KVListRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// Optional prefix to filter keys by.
|
|
Prefix string `protobuf:"bytes,1,opt,name=prefix,proto3" json:"prefix,omitempty"`
|
|
// The bucket to list from. Defaults to the caller's script name bucket
|
|
// if not specified.
|
|
Bucket string `protobuf:"bytes,2,opt,name=bucket,proto3" json:"bucket,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVListRequest) Reset() {
|
|
*x = KVListRequest{}
|
|
mi := &file_lit_scripts_proto_msgTypes[29]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVListRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVListRequest) ProtoMessage() {}
|
|
|
|
func (x *KVListRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[29]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVListRequest.ProtoReflect.Descriptor instead.
|
|
func (*KVListRequest) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{29}
|
|
}
|
|
|
|
func (x *KVListRequest) GetPrefix() string {
|
|
if x != nil {
|
|
return x.Prefix
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *KVListRequest) GetBucket() string {
|
|
if x != nil {
|
|
return x.Bucket
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type KVListResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// The keys in the bucket that match the prefix.
|
|
Keys []string `protobuf:"bytes,1,rep,name=keys,proto3" json:"keys,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *KVListResponse) Reset() {
|
|
*x = KVListResponse{}
|
|
mi := &file_lit_scripts_proto_msgTypes[30]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *KVListResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*KVListResponse) ProtoMessage() {}
|
|
|
|
func (x *KVListResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_lit_scripts_proto_msgTypes[30]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use KVListResponse.ProtoReflect.Descriptor instead.
|
|
func (*KVListResponse) Descriptor() ([]byte, []int) {
|
|
return file_lit_scripts_proto_rawDescGZIP(), []int{30}
|
|
}
|
|
|
|
func (x *KVListResponse) GetKeys() []string {
|
|
if x != nil {
|
|
return x.Keys
|
|
}
|
|
return nil
|
|
}
|
|
|
|
var File_lit_scripts_proto protoreflect.FileDescriptor
|
|
|
|
const file_lit_scripts_proto_rawDesc = "" +
|
|
"\n" +
|
|
"\x11lit-scripts.proto\x12\x06litrpc\x1a\x12lit-sessions.proto\"\x96\x03\n" +
|
|
"\x06Script\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\x12 \n" +
|
|
"\vdescription\x18\x02 \x01(\tR\vdescription\x12\x16\n" +
|
|
"\x06source\x18\x03 \x01(\tR\x06source\x12<\n" +
|
|
"\vpermissions\x18\x04 \x03(\v2\x1a.litrpc.MacaroonPermissionR\vpermissions\x12!\n" +
|
|
"\ftimeout_secs\x18\x05 \x01(\rR\vtimeoutSecs\x12,\n" +
|
|
"\x10max_memory_bytes\x18\x06 \x01(\x04B\x020\x01R\x0emaxMemoryBytes\x12!\n" +
|
|
"\fallowed_urls\x18\a \x03(\tR\vallowedUrls\x12'\n" +
|
|
"\x0fallowed_buckets\x18\b \x03(\tR\x0eallowedBuckets\x12!\n" +
|
|
"\n" +
|
|
"created_at\x18\t \x01(\x04B\x020\x01R\tcreatedAt\x12!\n" +
|
|
"\n" +
|
|
"updated_at\x18\n" +
|
|
" \x01(\x04B\x020\x01R\tupdatedAt\x12\x1d\n" +
|
|
"\n" +
|
|
"is_running\x18\v \x01(\bR\tisRunning\"\xbe\x02\n" +
|
|
"\x13CreateScriptRequest\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\x12 \n" +
|
|
"\vdescription\x18\x02 \x01(\tR\vdescription\x12\x16\n" +
|
|
"\x06source\x18\x03 \x01(\tR\x06source\x12<\n" +
|
|
"\vpermissions\x18\x04 \x03(\v2\x1a.litrpc.MacaroonPermissionR\vpermissions\x12!\n" +
|
|
"\ftimeout_secs\x18\x05 \x01(\rR\vtimeoutSecs\x12,\n" +
|
|
"\x10max_memory_bytes\x18\x06 \x01(\x04B\x020\x01R\x0emaxMemoryBytes\x12!\n" +
|
|
"\fallowed_urls\x18\a \x03(\tR\vallowedUrls\x12'\n" +
|
|
"\x0fallowed_buckets\x18\b \x03(\tR\x0eallowedBuckets\">\n" +
|
|
"\x14CreateScriptResponse\x12&\n" +
|
|
"\x06script\x18\x01 \x01(\v2\x0e.litrpc.ScriptR\x06script\"\xbe\x02\n" +
|
|
"\x13UpdateScriptRequest\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\x12 \n" +
|
|
"\vdescription\x18\x02 \x01(\tR\vdescription\x12\x16\n" +
|
|
"\x06source\x18\x03 \x01(\tR\x06source\x12<\n" +
|
|
"\vpermissions\x18\x04 \x03(\v2\x1a.litrpc.MacaroonPermissionR\vpermissions\x12!\n" +
|
|
"\ftimeout_secs\x18\x05 \x01(\rR\vtimeoutSecs\x12,\n" +
|
|
"\x10max_memory_bytes\x18\x06 \x01(\x04B\x020\x01R\x0emaxMemoryBytes\x12!\n" +
|
|
"\fallowed_urls\x18\a \x03(\tR\vallowedUrls\x12'\n" +
|
|
"\x0fallowed_buckets\x18\b \x03(\tR\x0eallowedBuckets\">\n" +
|
|
"\x14UpdateScriptResponse\x12&\n" +
|
|
"\x06script\x18\x01 \x01(\v2\x0e.litrpc.ScriptR\x06script\"O\n" +
|
|
"\x13DeleteScriptRequest\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\x12$\n" +
|
|
"\x0edelete_kv_data\x18\x02 \x01(\bR\fdeleteKvData\"\x16\n" +
|
|
"\x14DeleteScriptResponse\"&\n" +
|
|
"\x10GetScriptRequest\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\";\n" +
|
|
"\x11GetScriptResponse\x12&\n" +
|
|
"\x06script\x18\x01 \x01(\v2\x0e.litrpc.ScriptR\x06script\"\x14\n" +
|
|
"\x12ListScriptsRequest\"?\n" +
|
|
"\x13ListScriptsResponse\x12(\n" +
|
|
"\ascripts\x18\x01 \x03(\v2\x0e.litrpc.ScriptR\ascripts\"E\n" +
|
|
"\x12StartScriptRequest\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\x12\x1b\n" +
|
|
"\targs_json\x18\x02 \x01(\tR\bargsJson\"]\n" +
|
|
"\x13StartScriptResponse\x12%\n" +
|
|
"\fexecution_id\x18\x01 \x01(\x04B\x020\x01R\vexecutionId\x12\x1f\n" +
|
|
"\vresult_json\x18\x02 \x01(\tR\n" +
|
|
"resultJson\"'\n" +
|
|
"\x11StopScriptRequest\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\"\x14\n" +
|
|
"\x12StopScriptResponse\"\x1b\n" +
|
|
"\x19ListRunningScriptsRequest\"\\\n" +
|
|
"\x1aListRunningScriptsResponse\x12>\n" +
|
|
"\x0frunning_scripts\x18\x01 \x03(\v2\x15.litrpc.RunningScriptR\x0erunningScripts\"m\n" +
|
|
"\rRunningScript\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\x12%\n" +
|
|
"\fexecution_id\x18\x02 \x01(\x04B\x020\x01R\vexecutionId\x12!\n" +
|
|
"\n" +
|
|
"started_at\x18\x03 \x01(\x04B\x020\x01R\tstartedAt\"/\n" +
|
|
"\x15ValidateScriptRequest\x12\x16\n" +
|
|
"\x06source\x18\x01 \x01(\tR\x06source\"`\n" +
|
|
"\x16ValidateScriptResponse\x12\x14\n" +
|
|
"\x05valid\x18\x01 \x01(\bR\x05valid\x12\x14\n" +
|
|
"\x05error\x18\x02 \x01(\tR\x05error\x12\x1a\n" +
|
|
"\bwarnings\x18\x03 \x03(\tR\bwarnings\"^\n" +
|
|
"\x1aGetExecutionHistoryRequest\x12\x12\n" +
|
|
"\x04name\x18\x01 \x01(\tR\x04name\x12\x14\n" +
|
|
"\x05limit\x18\x02 \x01(\rR\x05limit\x12\x16\n" +
|
|
"\x06offset\x18\x03 \x01(\rR\x06offset\"V\n" +
|
|
"\x1bGetExecutionHistoryResponse\x127\n" +
|
|
"\n" +
|
|
"executions\x18\x01 \x03(\v2\x17.litrpc.ScriptExecutionR\n" +
|
|
"executions\"\x89\x02\n" +
|
|
"\x0fScriptExecution\x12\x12\n" +
|
|
"\x02id\x18\x01 \x01(\x04B\x020\x01R\x02id\x12\x1f\n" +
|
|
"\vscript_name\x18\x02 \x01(\tR\n" +
|
|
"scriptName\x12!\n" +
|
|
"\n" +
|
|
"started_at\x18\x03 \x01(\x04B\x020\x01R\tstartedAt\x12\x1d\n" +
|
|
"\bended_at\x18\x04 \x01(\x04B\x020\x01R\aendedAt\x12\x14\n" +
|
|
"\x05state\x18\x05 \x01(\tR\x05state\x12\x1f\n" +
|
|
"\vresult_json\x18\x06 \x01(\tR\n" +
|
|
"resultJson\x12#\n" +
|
|
"\rerror_message\x18\a \x01(\tR\ferrorMessage\x12#\n" +
|
|
"\vduration_ms\x18\b \x01(\x04B\x020\x01R\n" +
|
|
"durationMs\"8\n" +
|
|
"\fKVGetRequest\x12\x10\n" +
|
|
"\x03key\x18\x01 \x01(\tR\x03key\x12\x16\n" +
|
|
"\x06bucket\x18\x02 \x01(\tR\x06bucket\";\n" +
|
|
"\rKVGetResponse\x12\x14\n" +
|
|
"\x05value\x18\x01 \x01(\fR\x05value\x12\x14\n" +
|
|
"\x05found\x18\x02 \x01(\bR\x05found\"N\n" +
|
|
"\fKVPutRequest\x12\x10\n" +
|
|
"\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" +
|
|
"\x05value\x18\x02 \x01(\fR\x05value\x12\x16\n" +
|
|
"\x06bucket\x18\x03 \x01(\tR\x06bucket\"\x0f\n" +
|
|
"\rKVPutResponse\";\n" +
|
|
"\x0fKVDeleteRequest\x12\x10\n" +
|
|
"\x03key\x18\x01 \x01(\tR\x03key\x12\x16\n" +
|
|
"\x06bucket\x18\x02 \x01(\tR\x06bucket\"\x12\n" +
|
|
"\x10KVDeleteResponse\"?\n" +
|
|
"\rKVListRequest\x12\x16\n" +
|
|
"\x06prefix\x18\x01 \x01(\tR\x06prefix\x12\x16\n" +
|
|
"\x06bucket\x18\x02 \x01(\tR\x06bucket\"$\n" +
|
|
"\x0eKVListResponse\x12\x12\n" +
|
|
"\x04keys\x18\x01 \x03(\tR\x04keys2\xf3\a\n" +
|
|
"\aScripts\x12I\n" +
|
|
"\fCreateScript\x12\x1b.litrpc.CreateScriptRequest\x1a\x1c.litrpc.CreateScriptResponse\x12I\n" +
|
|
"\fUpdateScript\x12\x1b.litrpc.UpdateScriptRequest\x1a\x1c.litrpc.UpdateScriptResponse\x12I\n" +
|
|
"\fDeleteScript\x12\x1b.litrpc.DeleteScriptRequest\x1a\x1c.litrpc.DeleteScriptResponse\x12@\n" +
|
|
"\tGetScript\x12\x18.litrpc.GetScriptRequest\x1a\x19.litrpc.GetScriptResponse\x12F\n" +
|
|
"\vListScripts\x12\x1a.litrpc.ListScriptsRequest\x1a\x1b.litrpc.ListScriptsResponse\x12F\n" +
|
|
"\vStartScript\x12\x1a.litrpc.StartScriptRequest\x1a\x1b.litrpc.StartScriptResponse\x12C\n" +
|
|
"\n" +
|
|
"StopScript\x12\x19.litrpc.StopScriptRequest\x1a\x1a.litrpc.StopScriptResponse\x12[\n" +
|
|
"\x12ListRunningScripts\x12!.litrpc.ListRunningScriptsRequest\x1a\".litrpc.ListRunningScriptsResponse\x12O\n" +
|
|
"\x0eValidateScript\x12\x1d.litrpc.ValidateScriptRequest\x1a\x1e.litrpc.ValidateScriptResponse\x12^\n" +
|
|
"\x13GetExecutionHistory\x12\".litrpc.GetExecutionHistoryRequest\x1a#.litrpc.GetExecutionHistoryResponse\x124\n" +
|
|
"\x05KVGet\x12\x14.litrpc.KVGetRequest\x1a\x15.litrpc.KVGetResponse\x124\n" +
|
|
"\x05KVPut\x12\x14.litrpc.KVPutRequest\x1a\x15.litrpc.KVPutResponse\x12=\n" +
|
|
"\bKVDelete\x12\x17.litrpc.KVDeleteRequest\x1a\x18.litrpc.KVDeleteResponse\x127\n" +
|
|
"\x06KVList\x12\x15.litrpc.KVListRequest\x1a\x16.litrpc.KVListResponseB4Z2github.com/lightninglabs/lightning-terminal/litrpcb\x06proto3"
|
|
|
|
var (
|
|
file_lit_scripts_proto_rawDescOnce sync.Once
|
|
file_lit_scripts_proto_rawDescData []byte
|
|
)
|
|
|
|
func file_lit_scripts_proto_rawDescGZIP() []byte {
|
|
file_lit_scripts_proto_rawDescOnce.Do(func() {
|
|
file_lit_scripts_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_lit_scripts_proto_rawDesc), len(file_lit_scripts_proto_rawDesc)))
|
|
})
|
|
return file_lit_scripts_proto_rawDescData
|
|
}
|
|
|
|
var file_lit_scripts_proto_msgTypes = make([]protoimpl.MessageInfo, 31)
|
|
var file_lit_scripts_proto_goTypes = []any{
|
|
(*Script)(nil), // 0: litrpc.Script
|
|
(*CreateScriptRequest)(nil), // 1: litrpc.CreateScriptRequest
|
|
(*CreateScriptResponse)(nil), // 2: litrpc.CreateScriptResponse
|
|
(*UpdateScriptRequest)(nil), // 3: litrpc.UpdateScriptRequest
|
|
(*UpdateScriptResponse)(nil), // 4: litrpc.UpdateScriptResponse
|
|
(*DeleteScriptRequest)(nil), // 5: litrpc.DeleteScriptRequest
|
|
(*DeleteScriptResponse)(nil), // 6: litrpc.DeleteScriptResponse
|
|
(*GetScriptRequest)(nil), // 7: litrpc.GetScriptRequest
|
|
(*GetScriptResponse)(nil), // 8: litrpc.GetScriptResponse
|
|
(*ListScriptsRequest)(nil), // 9: litrpc.ListScriptsRequest
|
|
(*ListScriptsResponse)(nil), // 10: litrpc.ListScriptsResponse
|
|
(*StartScriptRequest)(nil), // 11: litrpc.StartScriptRequest
|
|
(*StartScriptResponse)(nil), // 12: litrpc.StartScriptResponse
|
|
(*StopScriptRequest)(nil), // 13: litrpc.StopScriptRequest
|
|
(*StopScriptResponse)(nil), // 14: litrpc.StopScriptResponse
|
|
(*ListRunningScriptsRequest)(nil), // 15: litrpc.ListRunningScriptsRequest
|
|
(*ListRunningScriptsResponse)(nil), // 16: litrpc.ListRunningScriptsResponse
|
|
(*RunningScript)(nil), // 17: litrpc.RunningScript
|
|
(*ValidateScriptRequest)(nil), // 18: litrpc.ValidateScriptRequest
|
|
(*ValidateScriptResponse)(nil), // 19: litrpc.ValidateScriptResponse
|
|
(*GetExecutionHistoryRequest)(nil), // 20: litrpc.GetExecutionHistoryRequest
|
|
(*GetExecutionHistoryResponse)(nil), // 21: litrpc.GetExecutionHistoryResponse
|
|
(*ScriptExecution)(nil), // 22: litrpc.ScriptExecution
|
|
(*KVGetRequest)(nil), // 23: litrpc.KVGetRequest
|
|
(*KVGetResponse)(nil), // 24: litrpc.KVGetResponse
|
|
(*KVPutRequest)(nil), // 25: litrpc.KVPutRequest
|
|
(*KVPutResponse)(nil), // 26: litrpc.KVPutResponse
|
|
(*KVDeleteRequest)(nil), // 27: litrpc.KVDeleteRequest
|
|
(*KVDeleteResponse)(nil), // 28: litrpc.KVDeleteResponse
|
|
(*KVListRequest)(nil), // 29: litrpc.KVListRequest
|
|
(*KVListResponse)(nil), // 30: litrpc.KVListResponse
|
|
(*MacaroonPermission)(nil), // 31: litrpc.MacaroonPermission
|
|
}
|
|
var file_lit_scripts_proto_depIdxs = []int32{
|
|
31, // 0: litrpc.Script.permissions:type_name -> litrpc.MacaroonPermission
|
|
31, // 1: litrpc.CreateScriptRequest.permissions:type_name -> litrpc.MacaroonPermission
|
|
0, // 2: litrpc.CreateScriptResponse.script:type_name -> litrpc.Script
|
|
31, // 3: litrpc.UpdateScriptRequest.permissions:type_name -> litrpc.MacaroonPermission
|
|
0, // 4: litrpc.UpdateScriptResponse.script:type_name -> litrpc.Script
|
|
0, // 5: litrpc.GetScriptResponse.script:type_name -> litrpc.Script
|
|
0, // 6: litrpc.ListScriptsResponse.scripts:type_name -> litrpc.Script
|
|
17, // 7: litrpc.ListRunningScriptsResponse.running_scripts:type_name -> litrpc.RunningScript
|
|
22, // 8: litrpc.GetExecutionHistoryResponse.executions:type_name -> litrpc.ScriptExecution
|
|
1, // 9: litrpc.Scripts.CreateScript:input_type -> litrpc.CreateScriptRequest
|
|
3, // 10: litrpc.Scripts.UpdateScript:input_type -> litrpc.UpdateScriptRequest
|
|
5, // 11: litrpc.Scripts.DeleteScript:input_type -> litrpc.DeleteScriptRequest
|
|
7, // 12: litrpc.Scripts.GetScript:input_type -> litrpc.GetScriptRequest
|
|
9, // 13: litrpc.Scripts.ListScripts:input_type -> litrpc.ListScriptsRequest
|
|
11, // 14: litrpc.Scripts.StartScript:input_type -> litrpc.StartScriptRequest
|
|
13, // 15: litrpc.Scripts.StopScript:input_type -> litrpc.StopScriptRequest
|
|
15, // 16: litrpc.Scripts.ListRunningScripts:input_type -> litrpc.ListRunningScriptsRequest
|
|
18, // 17: litrpc.Scripts.ValidateScript:input_type -> litrpc.ValidateScriptRequest
|
|
20, // 18: litrpc.Scripts.GetExecutionHistory:input_type -> litrpc.GetExecutionHistoryRequest
|
|
23, // 19: litrpc.Scripts.KVGet:input_type -> litrpc.KVGetRequest
|
|
25, // 20: litrpc.Scripts.KVPut:input_type -> litrpc.KVPutRequest
|
|
27, // 21: litrpc.Scripts.KVDelete:input_type -> litrpc.KVDeleteRequest
|
|
29, // 22: litrpc.Scripts.KVList:input_type -> litrpc.KVListRequest
|
|
2, // 23: litrpc.Scripts.CreateScript:output_type -> litrpc.CreateScriptResponse
|
|
4, // 24: litrpc.Scripts.UpdateScript:output_type -> litrpc.UpdateScriptResponse
|
|
6, // 25: litrpc.Scripts.DeleteScript:output_type -> litrpc.DeleteScriptResponse
|
|
8, // 26: litrpc.Scripts.GetScript:output_type -> litrpc.GetScriptResponse
|
|
10, // 27: litrpc.Scripts.ListScripts:output_type -> litrpc.ListScriptsResponse
|
|
12, // 28: litrpc.Scripts.StartScript:output_type -> litrpc.StartScriptResponse
|
|
14, // 29: litrpc.Scripts.StopScript:output_type -> litrpc.StopScriptResponse
|
|
16, // 30: litrpc.Scripts.ListRunningScripts:output_type -> litrpc.ListRunningScriptsResponse
|
|
19, // 31: litrpc.Scripts.ValidateScript:output_type -> litrpc.ValidateScriptResponse
|
|
21, // 32: litrpc.Scripts.GetExecutionHistory:output_type -> litrpc.GetExecutionHistoryResponse
|
|
24, // 33: litrpc.Scripts.KVGet:output_type -> litrpc.KVGetResponse
|
|
26, // 34: litrpc.Scripts.KVPut:output_type -> litrpc.KVPutResponse
|
|
28, // 35: litrpc.Scripts.KVDelete:output_type -> litrpc.KVDeleteResponse
|
|
30, // 36: litrpc.Scripts.KVList:output_type -> litrpc.KVListResponse
|
|
23, // [23:37] is the sub-list for method output_type
|
|
9, // [9:23] is the sub-list for method input_type
|
|
9, // [9:9] is the sub-list for extension type_name
|
|
9, // [9:9] is the sub-list for extension extendee
|
|
0, // [0:9] is the sub-list for field type_name
|
|
}
|
|
|
|
func init() { file_lit_scripts_proto_init() }
|
|
func file_lit_scripts_proto_init() {
|
|
if File_lit_scripts_proto != nil {
|
|
return
|
|
}
|
|
file_lit_sessions_proto_init()
|
|
type x struct{}
|
|
out := protoimpl.TypeBuilder{
|
|
File: protoimpl.DescBuilder{
|
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
RawDescriptor: unsafe.Slice(unsafe.StringData(file_lit_scripts_proto_rawDesc), len(file_lit_scripts_proto_rawDesc)),
|
|
NumEnums: 0,
|
|
NumMessages: 31,
|
|
NumExtensions: 0,
|
|
NumServices: 1,
|
|
},
|
|
GoTypes: file_lit_scripts_proto_goTypes,
|
|
DependencyIndexes: file_lit_scripts_proto_depIdxs,
|
|
MessageInfos: file_lit_scripts_proto_msgTypes,
|
|
}.Build()
|
|
File_lit_scripts_proto = out.File
|
|
file_lit_scripts_proto_goTypes = nil
|
|
file_lit_scripts_proto_depIdxs = nil
|
|
}
|