Previous Topic: Removing VSS Snapshots from Replica Servers: delete_snapshot()Next Topic: Gathering Statistics APIs


Getting Lists of VSS Snapshots from Replica Servers: get_snapshot_list()

The get_snapshot_list API function lets you get a list of the VSS snapshots from a host.

Arguments

The get_snapshot_list API function includes the arguments described in the following table:

Name

Type

Description

session_id

uint

The session ID that was returned by calling the create_session API.

host_name

string

The engine host name

ip_string

string

The IP address of the host_name.

host_port

ushort

The engine port number. Typically, the port number is 25000.

snapshot_list

out string

The volume snapshot list.

why_not_reason

out string

Contains the reason for failure when this API fails.

Return Values

The return type is Boolean. When the return value is true, the API completed successfully. When the return value is false, the API did not complete successfully. If the return value is false, review the message to determine the reason the API failed.

Example

public bool get_snapshot_list_example()
        {
            try
            {
                string host_name = "155.35.66.142";
                string ip_string = "155.35.66.142";
                ushort host_port = 25000;
                string snapshot_list = "";
                string why_not_reason = "";
                return get_mng().get_snapshot_list(session_id, host_name, ip_string, host_port, out snapshot_list, out why_not_reason);
            }
            catch (Exception ex)
            {
                System.Windows.Forms.MessageBox.Show(ex.Message);
            }
            return false;
        }