api - how to start to write an SDK for php MVC self created framework -



api - how to start to write an SDK for php MVC self created framework -

i don't know how inquire question ,but here comes:

my boss wanted me create simple mvc php our online-shopping website , did ( watching youtube , ...) , it's simple , made .

now keeps asking me :

first create restful api ( uses curl ).

second create documented sdk !!.

i've searched lot (really ) , right know can understand api i'm not sure what's sdk , how start write code

can give me line of code of illustration of how start write ?

what means **well documented ** ?

i've searched in google , know sdk , api literally mean, problem can't create relation between mvc , api , sdk .

how can start write api ?

where should begin ?

what's point ?

can give me illustration ?

what sdk supposed ?

i've seen lots of videos api , of them talks using rest , rest , should get/post/delete/put , on , forcefulness .

but should start ?

edit

in case , online-shopping searchs through our mongodb database , returns new products , other simple tasks , how should utilize restful api ? or skd ?

thanks , please tell me if explanation not understandable .

looks have task ahead of you.

restful routing

restful routing way of communicating server via standard http protocols. these things get, post, put, delete, etc...

when routing in restful way, not need phone call ambiguous methods retrieve, update, or delete info on server.

for example, when attempting retrieve users server, might have create phone call http://domain.tld/getallusers.php. not restful.

however, if retrieve users making phone call http://domain.tld/users/ , specify want access phone call via get, built in http protocol, restful.

there many resources online learning more restful routing.

apis

apis application programming interafaces. instance, when using restful routing construction application, implementing api, because giving others way access info on server.

however, apis not restful. in fact, many not, , these more hard application programmers larn because not follow standard.

there have been many books written apis , more can cover in response. book recommend build apis won't hate phil sturgeon.

sdks

sdks software development kits , while of time extensive, restful api developing constitute sdk.

this might not boss wants though, have inquire him.

documentation

well documented code easy read , easy understand. require grasp of language target audience uses.

the first step in writing documentation writing commented code. having commented code best documentation can have , after written, can utilize tool such phpdoc generate documentation you. generation might not extensive like, , means need more comments.

some recommendations

read through code other developers have implemented things seeking. biased in instance because current framework of choice, laravel php mvc framework of well. code documented , easy understand.

in addition, there lot of written packages on packagist might of help you, should check them out , composer if haven't already.

if reading finds mistakes please right me.

php api rest sdk

Comments

Popular posts from this blog

Delphi change the assembly code of a running process -

json - Hibernate and Jackson (java.lang.IllegalStateException: Cannot call sendError() after the response has been committed) -

C++ 11 "class" keyword -