Notice: Over the next few months, we're reorganizing the App Engine documentation site to make it easier to find content and better align with the rest of Google Cloud products. The same content will be available, but the navigation will now match the rest of the Cloud products.

Python 3.10 is now generally available.


Store one or more entities in the datastore.

The entities may be new or previously existing. For new entities, Put() will fill in the app id and key assigned by the datastore.

If the argument is a single Entity, a single Key will be returned. If the argument is a list of Entity, a list of Keys will be returned.

entities Entity or list of Entities
config Optional Configuration to use for this request, must be specified as a keyword argument.

Key or list of Keys

TransactionFailedError, if the Put could not be committed.