Documentation

Encrypts a file with a topic AES key. This is not available in CircleService, but is in CoreL2.

Arguments

The Circle ID, the Topic ID, and the inner and outer file paths. 

Returns

Whether the action was successful or not.

API Definition

public async Task<EncryptFileReply> EncryptFile(EncryptFileRequest request)

C# Structures

public class EncryptFileRequest

{

  public string CircleId;

  public string TopicId;

  public string InFilePath;

  public string OutFilePath;

}

public class EncryptFileReply

{

  public ReturnStatus Status;

}

C# Example code:

public void EncryptFile(string circleId, string topicId, string inFile, string outfile)

{

  EncryptFileRequest request = new EncryptFileRequest()

    { CircleId = circleId, TopicId = topicId, InFilePath = inFile, OutFilePath = outfile};

  EncryptFileReply reply = _circle.EncryptFile(request);

  if (reply.Status.Result)

  {

    Console.WriteLine(reply.Status.Message);

  }

  else

    Console.WriteLine(reply.Status.Message);

}