Current time: 04-27-2024, 12:33 PM Hello There, Guest! (LoginRegister)


Post Reply 
API
Author Message
antonypuckey Offline
Junior Member
*

Posts: 14
Joined: May 2008
Reputation: 0
Post: #1
API
Hi there,

So I'm making an API because I have no idea when the API will be released with ispcp. I'm no expert programmer, so I expect it to be buggy to start with.

I'm developing it with Zend framework and NuSoap. You will need to have an APIKey and a ResellerKey to communicate with it. Currently I am making the following functions for it.

addDomain - done
addEmailAddress - done
addCatchAll - done
addSubDomain - done
addAliasDomain - done
addDNSRecord - done
addFTPUser - done
addSQLDatabase - done
addSQLDatabaseUser - done

updateSQLDatabaseUser - done
updateDomain - done
updateEmailAddress - done
updateFTPUser
updateDNSRecord
updateAliasDomain - done

removeSQLDatabaseUser
removeSQLDatabase - done
removeFTPUser - done
removeDomainAlias - done
removeSubDomain - done
removeDNSRecord - done
removeCatchAll - done
removeEmailAddress - done
removeDomain

getDNSRecordList - done
getSubDomainList - done
getAliasDomainList - done
getMailList - done
getHostingPlans - done
getServerIPs - done
getDomainList - done

I personally need this so i can have 1 central "control center" and many ispcp installations so i can manage it all in the one place. But there would be many other uses I am sure..

I'll update this thread with more info once I have completed more of the API.

Cheers

EDIT: Updated function list.
EDIT: Updated function list with progress.
(This post was last modified: 12-24-2010 07:12 PM by antonypuckey.)
11-07-2010 10:38 AM
Find all posts by this user Quote this message in a reply
antonypuckey Offline
Junior Member
*

Posts: 14
Joined: May 2008
Reputation: 0
Post: #2
RE: API
I'm about 50% done. Probably about 2 days time ill have a working version to upload!
11-07-2010 05:49 PM
Find all posts by this user Quote this message in a reply
sci2tech Away
Senior Member
****

Posts: 1,285
Joined: Jan 2007
Reputation: 23
Post: #3
RE: API
If you do it we shall check and see if this can be merged safely into trunk
11-07-2010 08:54 PM
Visit this user's website Find all posts by this user Quote this message in a reply
antonypuckey Offline
Junior Member
*

Posts: 14
Joined: May 2008
Reputation: 0
Post: #4
RE: API
Just an update before I slink off to bed. The core API functionality is done. The following functions have been completed and tested.

removeFTPUser
removeDomainAlias
removeSubDomain
removeDNSRecord
removeCatchAll

getDNSRecordList
getSubDomainList
getAliasDomainList
getMailList

updateEmailAddress

Once I have finished all functions I will add logging and add additional security checks before i upload it to this thread.

Will post more information tomorrow.

Cheers!
11-07-2010 10:32 PM
Find all posts by this user Quote this message in a reply
Snooops Offline
Junior Member
*****
Dev Team

Posts: 89
Joined: Nov 2009
Reputation: 0
Post: #5
RE: API
Why are you using ZendFramework? its a really big overhead.
11-09-2010 12:07 AM
Find all posts by this user Quote this message in a reply
spidersoftware Offline
Junior Member
*

Posts: 80
Joined: Apr 2010
Reputation: 0
Post: #6
RE: API
Fantastic, i want test when finish, a Greet.
11-09-2010 04:11 AM
Find all posts by this user Quote this message in a reply
kassah Offline
Junior Member
*

Posts: 46
Joined: Oct 2010
Reputation: 1
Post: #7
RE: API
(11-09-2010 12:07 AM)Snooops Wrote:  Why are you using ZendFramework? its a really big overhead.

Only if you include everything including the kitchen sink in your package. It is easy to just slim it down to what you use, it's a component based system, so you're by no means required to use all of it.
11-10-2010 02:18 AM
Find all posts by this user Quote this message in a reply
Snooops Offline
Junior Member
*****
Dev Team

Posts: 89
Joined: Nov 2009
Reputation: 0
Post: #8
RE: API
(11-10-2010 02:18 AM)kassah Wrote:  
(11-09-2010 12:07 AM)Snooops Wrote:  Why are you using ZendFramework? its a really big overhead.

Only if you include everything including the kitchen sink in your package. It is easy to just slim it down to what you use, it's a component based system, so you're by no means required to use all of it.

i know about ZendFramework and im only using it to communicate between programms, because php isnt very usefull for it. But here we just got an API for the backend right? The API should give some functions which manipulate the database like ispcp daemon want. So there is no need to pick a 50MB Framework into the package which has no use here. It would be more faster if it would come without it. But its just a suggestion ;-)
At least i suspect nothing else more than a php file with a lot of functions full of mysql querys ;-). If im wrong, im sorry and failed ;-)

Greetings,
Snooops
11-10-2010 02:41 AM
Find all posts by this user Quote this message in a reply
antonypuckey Offline
Junior Member
*

Posts: 14
Joined: May 2008
Reputation: 0
Post: #9
RE: API
Sorry for not replying in a could of days. Been really busy with work.

Attached is a rough image of how I'm designing it. the JSON interface is theoretical at the moment. But could potentially be added without too much hassle if you wanted to extend it.

[Image: ispcp-api.jpg]
11-11-2010 03:34 PM
Find all posts by this user Quote this message in a reply
aseques Offline
Member
*****
Dev Team

Posts: 330
Joined: May 2008
Reputation: 4
Post: #10
RE: API
Hey, in case you need the sql stuff needed for the functions, I've done a script in php that can create almost all the components of a ispcp installation.
The objective in my case was to be able to script the creation of a domain (creating mailboxes, webspace, etc) and to make the transition from plesk easier.
Feel free to use anything you like of it. The code is probably a disaster, but it does what it promises ;P

http://isp-control.net/forum/thread-4255.html
11-11-2010 08:35 PM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)