// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.
package org_tangled
// schema: org.tangled.temp.spindle.quota.releaseNars
import (
"context"
"github.com/bluesky-social/indigo/lex/util"
)
const (
TempSpindleQuotaReleaseNarsNSID = "org.tangled.temp.spindle.quota.releaseNars"
)
// TempSpindleQuotaReleaseNars_Input is the input argument to a org.tangled.temp.spindle.quota.releaseNars call.
type TempSpindleQuotaReleaseNars_Input struct {
// nars: nars to release, as cache keys like nar/<hash>.nar.xz (a bare file name works too) or as nix store paths like /nix/store/<hash>-name
Nars []string `json:"nars" cborgen:"nars"`
}
// TempSpindleQuotaReleaseNars_Output is the output of a org.tangled.temp.spindle.quota.releaseNars call.
type TempSpindleQuotaReleaseNars_Output struct {
// bytes: cache storage bytes given back
Bytes int64 `json:"bytes" cborgen:"bytes"`
// released: how many allocations were deleted
Released int64 `json:"released" cborgen:"released"`
// unmatched: the inputs that matched no allocation
Unmatched []string `json:"unmatched" cborgen:"unmatched"`
}
// TempSpindleQuotaReleaseNars calls the XRPC method "org.tangled.temp.spindle.quota.releaseNars".
func TempSpindleQuotaReleaseNars(ctx context.Context, c util.LexClient, input *TempSpindleQuotaReleaseNars_Input) (*TempSpindleQuotaReleaseNars_Output, error) {
var out TempSpindleQuotaReleaseNars_Output
if err := c.LexDo(ctx, util.Procedure, "application/json", "org.tangled.temp.spindle.quota.releaseNars", nil, input, &out); err != nil {
return nil, err
}
return &out, nil
}