Box.V2.Managers.BoxRetentionPoliciesManager.GetFileVersionRetentionsAsync C# (CSharp) Method

GetFileVersionRetentionsAsync() public method

Retrieves all file version retentions for the given enterprise.
public GetFileVersionRetentionsAsync ( List fields = null, int limit = 100, string marker = null, bool autoPaginate = false ) : Task>
fields List Attribute(s) to include in the response.
limit int Limit result size to this number. Defaults to 100, maximum is 1,000.
marker string Take from "next_marker" column of a prior call to get the next page.
autoPaginate bool Whether or not to auto-paginate to fetch all items; defaults to false.
return Task>
        public async Task<BoxCollectionMarkerBased<BoxFileVersionRetention>> GetFileVersionRetentionsAsync(List<string> fields = null, int limit = 100, string marker = null, bool autoPaginate = false)
        {
            BoxRequest request = new BoxRequest(_config.FileVersionRetentionsUri)
                .Param(ParamFields, fields)
                .Param("limit", limit.ToString())
                .Param("marker", marker);

            if (autoPaginate)
            {
                return await AutoPaginateMarker<BoxFileVersionRetention>(request, limit);
            }
            else
            {
                var response = await ToResponseAsync<BoxCollectionMarkerBased<BoxFileVersionRetention>>(request).ConfigureAwait(false);
                return response.ResponseObject;
            }
        }