예제 #1
0
        /// <summary>
        /// Creates a new Plan
        /// </summary>
        /// <param name="name">The name of the plan</param>
        /// <param name="reference">The reference</param>
        /// <param name="description">The plan description</param>
        /// <param name="amount">The plan amount, as an integer</param>
        /// <returns>Response</returns>
        public static Response <Plan> Create(string name, string reference, string description, int amount)
        {
            var req = new Requests.Plan {
                Name        = name,
                Description = description,
                Reference   = reference,
                Amount      = amount,
                TestMode    = Gateway.TestMode
            };

            return(Gateway.Post <Plan>("plans.json", req));
        }
예제 #2
0
        /// <summary>
        /// Creates a new Plan
        /// </summary>
        /// <param name="name">The name of the plan</param>
        /// <param name="reference">The reference</param>
        /// <param name="description">The plan description</param>
        /// <param name="amount">The plan amount, as an integer</param>
        /// <returns>Response</returns>
		public static Response<Plan> Create(string name, string reference, string description, int amount)
        {
			var req = new Requests.Plan {
				Name = name,
				Description = description,
				Reference = reference,
				Amount = amount,
				TestMode = Gateway.TestMode
			};

			return Gateway.Post<Plan>("plans.json", req);
        }