A common edit response for Server Images.
JSON Response
{
"list": [{
"billingtokens": [{
"id": 22,
"name": "Windows 2008 32bit",
"price": 0
}],
"createdTime": 1248385571829,
"description": "This is my 2003 Windows Server Image",
"friendlyName": "Windows 2k3 Image",
"id": 250,
"isActive": true,
"isPublic": false,
"location": "19999/GSI-d8fbf7d7-6c0c-47f5-9fb6-9211ed2fe64e.img",
"name": "GSI-d8fbf7d7-6c0c-47f5-9fb6-9211ed2fe64e",
"object": "image",
"os": {
"description": "Windows 2008 Server (32-bit)",
"id": 11,
"name": "Windows 2008 Server (32-bit)",
"object": "option"
},
"owner": {
"id": 19999,
"name": "Servepath",
"object": "customer"
},
"price": 0,
"state": {
"description": "Image is available for adds",
"id": 2,
"name": "Available",
"object": "option"
},
"type": {
"description": "Web or Application Server",
"id": 1,
"name": "Web Server",
"object": "option"
},
"updatedTime": 1250787768488
}],
"method": "/grid/image/edit",
"status": "success",
"summary": {
"numpages": 0,
"returned": 1,
"start": 0,
"total": 1
}
}
XML Response
<gogrid>
<response method="/grid/image/edit" status="success">
<summary total="1" start="0" numpages="0" returned="1"/>
<list>
<object name="image">
<attribute name="id">250</attribute>
<attribute name="friendlyName">Windows 2k3 Image</attribute>
<attribute name="name">GSI-d8fbf7d7-6c0c-47f5-9fb6-9211ed2fe64e</attribute>
<attribute name="os">
<object name="option">
<attribute name="id">11</attribute>
<attribute name="name">Windows 2008 Server (32-bit)</attribute>
<attribute name="description">Windows 2008 Server (32-bit)</attribute>
</object>
</attribute>
<attribute name="owner">
<object name="customer">
<attribute name="id">19999</attribute>
<attribute name="name">Servepath</attribute>
</object>
</attribute>
<attribute name="type">
<object name="option">
<attribute name="id">1</attribute>
<attribute name="name">Web Server</attribute>
<attribute name="description">Web or Application Server</attribute>
</object>
</attribute>
<attribute name="state">
<object name="option">
<attribute name="id">2</attribute>
<attribute name="name">Available</attribute>
<attribute name="description">Image is available for adds</attribute>
</object>
</attribute>
<attribute name="description">This is my 2003 Windows Server Image</attribute>
<attribute name="location">19999/GSI-d8fbf7d7-6c0c-47f5-9fb6-9211ed2fe64e.img</attribute>
<attribute name="price">0.0</attribute>
<attribute name="isActive">true</attribute>
<attribute name="isPublic">false</attribute>
<attribute name="createdTime">1248385571829</attribute>
<attribute name="updatedTime">1250787712134</attribute>
<attribute name="billingtokens"> <list>
<object name="billingtoken">
<attribute name="id">22</attribute>
<attribute name="name">Windows 2008 32bit</attribute>
<attribute name="price">0.0</attribute>
</object>
</list> </attribute> </object>
</list>
</response>
</gogrid>
CSV Response
# SUCCESS, /grid/image/edit, TOTAL, 1, NUMPAGES, 0, START, 0, RETURNED, 1
# server.id,server.name,id,friendlyName,name,os.id,os.name,os.description,architecture.id,architecture.name,architecture.description,owner.id,owner.name,type.id,type.name,type.description,state.id,state.name,state.description,description,location,price,isActive,isPublic,createdTime,updatedTime,billingtokens.1.id,billingtokens.1.name,billingtokens.1.price
,,250,Windows 2k3 Image,GSI-d8fbf7d7-6c0c-47f5-9fb6-9211ed2fe64e,11,Windows 2008 Server (32-bit),Windows 2008 Server (32-bit),,,,19999,Servepath,1,Web Server,Web or Application Server,2,Available,Image is available for adds,This is my 2003 Windows Server Image,19999/GSI-d8fbf7d7-6c0c-47f5-9fb6-9211ed2fe64e.img,0.0,true,false,1248385571829,1250787784434,22,Windows 2008 32bit,0.0,
Error Codes
| 400
| IllegalArgumentException
| Any problems with input parameters will generate an IllegalArgumentException.
|
| 401
| Unauthorized
| This error code will occur when the role tied to the API Key in your request has the wrong Access Controls.
|
| 403
| Authentication Failed
| This error code will occur when your request is not properly signed. Make sure your have a valid API key and secret and that you are properly generating a request signature. Ensure that the clock on the computer from which you are making the request is synchronized woth the GoGrid API Server.
|
| 404
| Not Found
| This error will occur if you have specified a method that does not exist or any other URL does not exists on the API Server.
|
| 500
| UnexpectedError
| These types of errors indicate an internal system problem. Depending on the severity of the error and whether not it is blocking your development, report the error to GoGrid support by emailing the response to apisupport@gogrid.com.
|