package remote_api
import "google.golang.org/appengine/remote_api"
Package remote_api implements the /_ah/remote_api endpoint. This endpoint is used by offline tools such as the bulk loader.
Index ¶
Examples ¶
Functions ¶
func NewRemoteContext ¶
NewRemoteContext returns a context that gives access to the production APIs for the application at the given host. All communication will be performed over SSL unless the host is localhost.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a connection to the production APIs for an application.
Code:
Example¶
{
c, err := NewClient("example.appspot.com", http.DefaultClient)
if err != nil {
log.Fatal(err)
}
ctx := context.Background() // or from a request
ctx = c.NewContext(ctx)
_, err = datastore.Put(ctx, datastore.NewIncompleteKey(ctx, "Foo", nil), struct{ Bar int }{42})
if err != nil {
log.Fatal(err)
}
}
func NewClient ¶
NewClient returns a client for the given host. All communication will be performed over SSL unless the host is localhost.
func (*Client) NewContext ¶
NewContext returns a copy of parent that will cause App Engine API calls to be sent to the client's remote host.
Source Files ¶
client.go remote_api.go
- Version
- v1.1.0
- Published
- May 21, 2018
- Platform
- js/wasm
- Imports
- 19 packages
- Last checked
- 7 hours ago –
Tools for package owners.