See pods() for more information about the various methods themselves.
Contents
Add a pod item
$ wp pods add --pod=my_pod --my_field_name1=Value --my_field_name2="Another Value" Pod item added. New ID: 123
Save a pod item
$ wp pods save --pod=my_pod --item=123 --my_field_name1=Value2 --my_field_name2="Another Value2" Pod item saved. ID: 123 $ wp pods save --pod=my_settings_pod --my_option_field_name1=Value --my_option_field_name2="Another Value2" Pod item saved. ID: my_settings_pod
Duplicate a pod item
$ wp pods duplicate --pod=my_pod --item=123 Pod item duplicated. New ID: 124
Delete a pod item
$ wp pods delete --pod=my_pod --item=123 Pod item deleted.
Export a single pod item to a file
$ wp pods export-item --pod=my_pod --item=123 --file="item-data.json" Pod item exported: /your/wp/path/item-data.json $ wp pods export-item --pod=my_pod --item=123 --file="/path/to/item-data.json" Pod item exported: /path/to/item-data.json $ wp pods export-item --pod=my_pod --item=123 --file="item-data.json" --fields="ID,post_title,post_content,my_field_name1,my_field_name2" Pod item exported: /your/wp/path/item-data.json $ wp pods export-item --pod=my_pod --item=123 --file="item-data.json" --depth=2 Pod item exported: /your/wp/path/item-data.json
Export all pod items to a file
$ wp pods export --pod=my_pod --file="items.json" Pod items exported: /your/wp/path/items.json $ wp pods export --pod=my_pod --file="/path/to/items.json" Pod items exported: /path/to/items.json $ wp pods export --pod=my_pod --file="items.json" --fields="ID,post_title,post_content,my_field_name1,my_field_name2" Pod items exported: /your/wp/path/items.json $ wp pods export --pod=my_pod --file="items.json" --depth=2 Pod items exported: /your/wp/path/items.json $ wp pods export --pod=my_pod --file="items.json" --params="{\"limit\":10,\"orderby\":\"t.ID DESC\"}" Pod items exported: /your/wp/path/items.json $ wp pods export --pod=my_pod --file="items.json" --params="limit=10&orderby=t.ID DESC" Pod items exported: /your/wp/path/items.json