diff --git a/official/docs/csharp/current/child-users/list.cs b/official/docs/csharp/current/child-users/list.cs new file mode 100644 index 00000000..2413925b --- /dev/null +++ b/official/docs/csharp/current/child-users/list.cs @@ -0,0 +1,29 @@ +using System; +using System.Collections.Generic; +using System.Threading.Tasks; +using Newtonsoft.Json; +using EasyPost; +using EasyPost.Models.API; +using EasyPost.Parameters; + +namespace EasyPostExamples +{ + public class Examples + { + public static async Task Main() + { + string apiKey = Environment.GetEnvironmentVariable("EASYPOST_API_KEY")!; + + var client = new EasyPost.Client(apiKey); + + Parameters.Users.AllChildren parameters = new() + { + PageSize = 5 + }; + + ChildUserCollection childUserCollection = await client.User.AllChildren(parameters); + + Console.WriteLine(JsonConvert.SerializeObject(childUserCollection, Formatting.Indented)); + } + } +} diff --git a/official/docs/curl/current/child-users/list.sh b/official/docs/curl/current/child-users/list.sh new file mode 100644 index 00000000..78ccfd79 --- /dev/null +++ b/official/docs/curl/current/child-users/list.sh @@ -0,0 +1,2 @@ +curl -X GET https://api.easypost.com/v2/users/children?page_size=5 \ + -u "$EASYPOST_API_KEY": diff --git a/official/docs/golang/current/child-users/list.go b/official/docs/golang/current/child-users/list.go new file mode 100644 index 00000000..6883594c --- /dev/null +++ b/official/docs/golang/current/child-users/list.go @@ -0,0 +1,21 @@ +package example + +import ( + "fmt" + "os" + + "github.com/EasyPost/easypost-go/v3" +) + +func main() { + apiKey := os.Getenv("EASYPOST_API_KEY") + client := easypost.New(apiKey) + + childUsers, _ := client.ListChildUsers( + &easypost.ListOptions{ + PageSize: 5, + }, + ) + + fmt.Println(childUsers) +} diff --git a/official/docs/node/current/child-users/list.js b/official/docs/node/current/child-users/list.js new file mode 100644 index 00000000..d8258db2 --- /dev/null +++ b/official/docs/node/current/child-users/list.js @@ -0,0 +1,11 @@ +const EasyPostClient = require('@easypost/api'); + +const client = new EasyPostClient(process.env.EASYPOST_API_KEY); + +(async () => { + const childUsers = await client.User.allChildren({ + page_size: 5, + }); + + console.log(childUsers); +})(); diff --git a/official/docs/php/current/child-users/list.php b/official/docs/php/current/child-users/list.php new file mode 100644 index 00000000..357b6b0b --- /dev/null +++ b/official/docs/php/current/child-users/list.php @@ -0,0 +1,9 @@ +user->allChildren([ + 'page_size' => 5 +]); + +echo $childUsers; diff --git a/official/docs/python/current/child-users/list.py b/official/docs/python/current/child-users/list.py new file mode 100644 index 00000000..86d6f33f --- /dev/null +++ b/official/docs/python/current/child-users/list.py @@ -0,0 +1,8 @@ +import easypost +import os + +client = easypost.EasyPostClient(os.getenv("EASYPOST_API_KEY")) + +childUsers = client.user.all_children(page_size=5) + +print(childUsers) diff --git a/official/docs/ruby/current/child-users/list.rb b/official/docs/ruby/current/child-users/list.rb new file mode 100644 index 00000000..79363496 --- /dev/null +++ b/official/docs/ruby/current/child-users/list.rb @@ -0,0 +1,9 @@ +require 'easypost' + +client = EasyPost::Client.new(api_key: ENV['EASYPOST_API_KEY']) + +child_users = client.user.all_children( + page_size: 5, +) + +puts child_users