Skip to content

Commit 3f31da6

Browse files
author
Nathan Beittenmiller
committed
Minor organization tweaks. Expanded table of contents to two levels to improve navigation
1 parent 91c0260 commit 3f31da6

3 files changed

Lines changed: 33 additions & 25 deletions

File tree

docs/api/client.rst

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,24 @@ Below is an example of creating a client instance with more options. This will c
4949
verbose=True,
5050
)
5151

52+
Managers
53+
--------
54+
::
55+
For day to day operation, most users will find the managers to be the most convenient means for interacting with the API. Managers mask out a lot of the complexities of using the API into classes that provide a simpler interface to various services. These are higher-level interfaces to the SoftLayer API.
56+
57+
58+
>>> from SoftLayer import CCIManager, Client
59+
>>> client = Client(...)
60+
>>> cci = CCIManager(client)
61+
>>> cci.list_instances()
62+
[...]
63+
64+
If you need more power or functionality than the managers provide, you can make direct API calls as well.
65+
66+
5267
Making API Calls
5368
----------------
54-
The SoftLayer API client for python leverages SoftLayer's XML-RPC API. It supports authentication, object masks, object filters, limits, offsets, and retrieving objects by id. The following section assumes you have a initialized client named 'client'.
69+
For full control over your account and services, you can directly call the SoftLayer API. The SoftLayer API client for python leverages SoftLayer's XML-RPC API. It supports authentication, object masks, object filters, limits, offsets, and retrieving objects by id. The following section assumes you have a initialized client named 'client'.
5570

5671
The best way to test our setup is to call the `getObject <http://sldn.softlayer.com/reference/services/SoftLayer_Account/getObject>`_ method on the `SoftLayer_Account <http://sldn.softlayer.com/reference/services/SoftLayer_Account>`_ service.
5772
::
@@ -135,18 +150,6 @@ API Reference
135150
:undoc-members:
136151

137152

138-
Managers
139-
--------
140-
::
141-
142-
>>> from SoftLayer import CCIManager, Client
143-
>>> client = Client(...)
144-
>>> cci = CCIManager(client)
145-
>>> cci.list_instances()
146-
[...]
147-
148-
Managers mask out a lot of the complexities of using the API into classes that provide a simpler interface to various services. These are higher-level interfaces to the SoftLayer API.
149-
150153
.. toctree::
151154
:maxdepth: 2
152155
:glob:

docs/cli.rst

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -69,24 +69,29 @@ To discover the available commands, simply type `sl`.
6969
::
7070

7171
$ sl
72-
usage: sl <command> [<args>...]
73-
sl help <command>
72+
usage: sl <module> [<args>...]
73+
sl help <module>
74+
sl help <module> <command>
7475
sl [-h | --help]
75-
76+
7677
SoftLayer Command-line Client
77-
78-
The available commands are:
79-
firewall Firewall rule and security management
80-
image Manages compute and flex images
81-
ssl Manages SSL
78+
79+
The available modules are:
8280
cci Manage, delete, order compute instances
83-
dns Manage DNS
8481
config View and edit configuration for this tool
82+
dns Manage DNS
83+
firewall Firewall rule and security management
84+
hardware View hardware details
85+
bmetal Interact with bare metal instances
86+
network Perform various network operations
87+
help Show help
88+
iscsi View iSCSI details
89+
image Manages compute and flex images
8590
metadata Get details about this machine. Also available with 'my' and 'meta'
8691
nas View NAS details
87-
iscsi View iSCSI details
92+
ssl Manages SSL
8893

89-
See 'sl help <command>' for more information on a specific command.
94+
See 'sl help <module>' for more information on a specific module.
9095

9196
To use most commands your SoftLayer username and api_key need to be configured.
9297
The easiest way to do that is to use: 'sl config setup'

docs/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ SoftLayer API Python Client |version|
55
This is the documentation to SoftLayer's Python API Bindings. These bindings use SoftLayer's `XML-RPC interface <http://sldn.softlayer.com/article/XML-RPC>`_ in order to manage SoftLayer services.
66

77
.. toctree::
8-
:maxdepth: 1
8+
:maxdepth: 2
99
:glob:
1010

1111
install

0 commit comments

Comments
 (0)