WebFaction
Community site: login faq
import xmlrpclib

server = xmlrpclib.ServerProxy('https://api.webfaction.com/', verbose=0)

session_id, account = server.login('foobar', 'foobar')

server.create_website(session_id,'widgets_on_the_web','127.0.0.1', True, ['shoppu.com'], [['django', 
'/']])

This is the result:

File "/home/marcos/dev/webfaction-api-piston-wrapper/webfaction_api_piston_wrapper/tests.py", line 15, in test_remote

server.create_website(session_id,'widgets_on_the_web','127.0.0.1', True, ['shoppu.com'], [['django', '/']])

File "/usr/lib/python2.6/xmlrpclib.py", line 1199, in call return self.send(self.name, args)

File "/usr/lib/python2.6/xmlrpclib.py", line 1489, in request verbose=self.verbose

File "/usr/lib/python2.6/xmlrpclib.py", line 1253, in request return self._parse_response(h.getfile(), sock)

File "/usr/lib/python2.6/xmlrpclib.py", line 1392, in _parse_response return u.close()

File "/usr/lib/python2.6/xmlrpclib.py", line 838, in close raise Fault(**self._stack[0])

Fault: Fault 1: 'list index out of range'

Which list index is out of bounds? How to create a website using xml-rpc api?

asked 14 Jun '11, 18:40

marcosmachado
112
accept rate: 0%

edited 14 Jun '11, 18:44


Are you using 127.0.0.1 for the IP on the live code? It should be the servers IP address, 127.0.0.1 will fail.

http://docs.webfaction.com/xmlrpc-api/apiref.html#websites-and-domains

Also does the application 'django' exist?

permanent link

answered 14 Jun '11, 20:25

johns
5.4k312
accept rate: 23%

edited 14 Jun '11, 20:27

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×337
×108
×75
×11

question asked: 14 Jun '11, 18:40

question was seen: 3,827 times

last updated: 14 Jun '11, 20:27

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM