Vana SDK - v2.2.2
    Preparing search index...

    Function validateOperationAccess

    • Validates that a grant authorizes the requested operation.

      Parameters

      • grantFile: GrantFile

        The grant file to check. Contains the authorized operation.

      • requestedOperation: string

        The operation to validate. Must match the grant's operation exactly.

      Returns void

      If operations don't match. Request a grant for the specific operation needed.

      validateOperationAccess(grantFile, 'llm_inference');
      // Throws if grantFile.operation !== 'llm_inference'