Anoma.CairoResource.Workflow (Anoma v0.29.0)

I am a bunch of workflow functions for creating a shielded transaction.

Summary

Functions

Link to this function

create_action(input_logic_proofs, output_logic_proofs, compliance_proofs)

Link to this function

create_compliance_inputs(compliance_pre_inputs, input_resources, output_resources)

@spec create_compliance_inputs(
  [Jason.OrderedObject.t()],
  [Anoma.CairoResource.Resource.t()],
  [
    Anoma.CairoResource.Resource.t()
  ]
) :: {:ok, [String.t()]} | {:error, term()}
Link to this function

create_merkle_tree_paths(input_nullifiers, output_commitments)

@spec create_merkle_tree_paths([binary()], [binary()]) ::
  {:ok, [[Jason.OrderedObject.t()]], [[Jason.OrderedObject.t()]]}
  | {:error, term()}
Link to this function

create_private_keys(compliance_input_jsons)

@spec create_private_keys([Jason.OrderedObject.t()]) ::
  {:ok, binary()} | {:error, term()}
Link to this function

generate_compliance_proofs(compliance_inputs)

@spec generate_compliance_proofs([String.t()]) ::
  {:ok, [Anoma.CairoResource.ProofRecord.t()]} | {:error, term()}
Link to this function

generate_resource_logic_proofs(resource_logics, resource_logic_witnesses)

@spec generate_resource_logic_proofs([binary()], [binary()]) ::
  {:ok, [Anoma.CairoResource.ProofRecord.t()]} | {:error, term()}
Link to this function

get_input_resources(jsons, resource_logics, input_nf_keys)

@spec get_input_resources([Jason.OrderedObject.t()], [binary()], [binary()]) ::
  {:ok, [Anoma.CairoResource.Resource.t()]} | {:error, term()}
Link to this function

get_output_resources(jsons, resource_logics, input_nullifiers)

@spec get_output_resources([Jason.OrderedObject.t()], [binary()], [binary()]) ::
  {:ok, [Anoma.CairoResource.Resource.t()]} | {:error, term()}
Link to this function

hash_resource_logic(resource_logic_bin)

@spec hash_resource_logic(binary()) :: {:ok, binary()} | {:error, term()}
Link to this function

update_witnesses(witnesses, resources, nf_keys, merkle_paths)

@spec update_witnesses([binary()], [Anoma.CairoResource.Resource.t()], [binary()], [
  [Jason.OrderedObject.t()]
]) :: {:ok, [binary()]} | {:error, term()}