Skip to content
This repository has been archived by the owner on Mar 22, 2024. It is now read-only.

Commit

Permalink
Use await syntax in README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
dennisbruner committed Sep 7, 2020
1 parent 58991f3 commit 307df3d
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,12 @@ let client = new HetznerCloud.Client('API_TOKEN')
### Build and create a server

```javascript
client.servers.build('my-awesome-server')
const { server } = await client.servers.build('my-awesome-server')
.serverType('cx11')
.location('nbg1')
.image('debian-9')
.sshKey('work')
.create()
.then(function (response) {
// The response object contains:
// response.server - The server class instance
// response.action - The action for creating this server
})
.catch(function (error) {
// Handle error...
})
```

## Documentation
Expand Down

0 comments on commit 307df3d

Please sign in to comment.