I'm trying to figure out is it possible to programmatically (e.g. via webservice) import document types exported from the back end UI?
I'd like to use such a functionality to extend our build process from Visual Studio so that when a project is built, document types from the project can be imported to the developers instance of Umbraco. We're using project setup with POST-Build event and XCOPY command that can be found on the Net.
Thanks Thomas, but as I said I'd need this functionality inside Visual Studio build process. I looked at the webservices ( /webservices/api ) but there isn't anything like that there.
What i'd like to do is to create a small program that could use web service calls, for example, to import all the udt files from the VS2008 project directory to the running Umbraco instance. This small program would then be part of the projects post-build event, thus enablig every developer on the project to easily work with the up-to-date document types. We'd keep udt files under version control.
I was thinking to create the webservice. I'll take a look at the source code to see how the actual import is done by the umbraco backend.
For the upcoming project we'll get the Umbraco Pro license, but untill then i'm looking into other ways of doing this (don't know if Courier can do this for us?)
I'm thinking to create a webservice that will extend /umbraco/webservices/api so that you can manipulate documentTypes in the same way as Documents, Media etc.
I'll have a look at the source code for the weekend, to see how import functionality actually does this and just expose that code as a service. Hopefully that should work. If it does, there will be one additional Umbraco project available ;)
Sounds like an interesting idea. Do post an update when you have found / developed a solution.
I have been thinking about doing something similar to allow a build server to automatically update a testing server based on a successful build which could then be used for some form of client side unit testing.
I am working on a tool that already does programmatically create document types, one thing to consider is how you would achieve hierachical document types in your import process.
Programmatically import document types
I'm trying to figure out is it possible to programmatically (e.g. via webservice) import document types exported from the back end UI?
I'd like to use such a functionality to extend our build process from Visual Studio so that when a project is built, document types from the project can be imported to the developers instance of Umbraco. We're using project setup with POST-Build event and XCOPY command that can be found on the Net.
Umbraco version is 4.0.2.1
Thanks!
You can create a package on the source system including the document types and then import it on the target system.
hth, Thomas
Thanks Thomas, but as I said I'd need this functionality inside Visual Studio build process. I looked at the webservices ( /webservices/api ) but there isn't anything like that there.
What i'd like to do is to create a small program that could use web service calls, for example, to import all the udt files from the VS2008 project directory to the running Umbraco instance. This small program would then be part of the projects post-build event, thus enablig every developer on the project to easily work with the up-to-date document types. We'd keep udt files under version control.
Hi Vanja,my fault, didn't read it exactly.
You can implement an own webservice which creates the document types. Didn't tried it yet, but should be possible like this:
Just to fill the lacks I left for you ;-)
Did this help? If you want I can look into it again.
hth, Thomas
Did you take a look into the umbImport project from Richard or the Courier from the Umbraco Pro licence?
Thomas
I was thinking to create the webservice. I'll take a look at the source code to see how the actual import is done by the umbraco backend.
For the upcoming project we'll get the Umbraco Pro license, but untill then i'm looking into other ways of doing this (don't know if Courier can do this for us?)
Hi Vanja,
I also had problems with up-to-date docTypes at every developers machine.
How are you going to call webservice from postbuild event?
I'm thinking to create a webservice that will extend /umbraco/webservices/api so that you can manipulate documentTypes in the same way as Documents, Media etc.
I'll have a look at the source code for the weekend, to see how import functionality actually does this and just expose that code as a service. Hopefully that should work. If it does, there will be one additional Umbraco project available ;)
Vanja,
Sounds like an interesting idea. Do post an update when you have found / developed a solution.
I have been thinking about doing something similar to allow a build server to automatically update a testing server based on a successful build which could then be used for some form of client side unit testing.
I am working on a tool that already does programmatically create document types, one thing to consider is how you would achieve hierachical document types in your import process.
Cheers,
Chris
Will do!
is working on a reply...