Example #1
0
        public void UpdateOperationParameter()
        {
            string apiId       = _apiId;
            string operationId = _operationId;

            APIOperation       entity = Client.GetAPIOperationAsync(apiId, operationId).Result;
            APIOperationHelper helper = new APIOperationHelper(entity);


            List <ParameterContract> parameters = new List <ParameterContract>();

            parameters.Add(ParameterContract.Create("account", "uuid"));
            parameters.Add(ParameterContract.Create("subscription", "uuid"));

            entity.UrlTemplate        = APIOperationHelper.BuildURL("/get", parameters);
            entity.TemplateParameters = parameters.ToArray();

            var task = Client.UpdateAPIOperationAsync(apiId, operationId, entity);

            task.Wait();
        }
Example #2
0
        public void UpdateOperationParameter()
        {
            string apiId       = "api_b8aad5c90425479c9e50c2513bfbc804";
            string operationId = "operation_be5ecb981a0d43678ae492502c925047";

            APIOperation       entity = Client.GetAPIOperationAsync(apiId, operationId).Result;
            APIOperationHelper helper = new APIOperationHelper(entity);


            List <ParameterContract> parameters = new List <ParameterContract>();

            parameters.Add(ParameterContract.Create("account", "uuid"));
            parameters.Add(ParameterContract.Create("subscription", "uuid"));

            entity.UrlTemplate        = APIOperationHelper.BuildURL("/get", parameters);
            entity.TemplateParameters = parameters.ToArray();

            var task = Client.UpdateAPIOperationAsync(apiId, operationId, entity);

            task.Wait();
        }