# Using Slicer via web service API

**URL:** <https://discourse.slicer.org/t/using-slicer-via-web-service-api/14368>\
**Category:** Development\
**Created:** [November 1, 2020, 1:43pm UTC](https://discourse.slicer.org/t/using-slicer-via-web-service-api/14368 "2020-11-01T13:43:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![puia](https://avatars.discourse-cdn.com/v4/letter/p/ea5d25/32.png) [@puia](https://discourse.slicer.org/u/puia)\
**Post date:** [November 1, 2020, 1:43pm UTC](https://discourse.slicer.org/t/using-slicer-via-web-service-api/14368/1 "2020-11-01T13:43:00Z")

</div>

hello  
i am new to this software and my research is under going and i and the end i found what i need here .  
a stack of 2d images out of a 3d stl image .  
i am implementing an web app in order to work with 3d stl file , in order to provide a machine learning model with a series of 2d images .

this is what i need to know :  
is there any way to use the 3Dslicer as an API service ?  
in order to use it should i install the decstop software ?

tnx

---

<div class="post-metadata">

**Author:** ![puia](https://avatars.discourse-cdn.com/v4/letter/p/ea5d25/32.png) [@puia](https://discourse.slicer.org/u/puia)\
**Post date:** [November 1, 2020, 3:41pm UTC](https://discourse.slicer.org/t/using-slicer-via-web-service-api/14368/2 "2020-11-01T15:41:36Z")

</div>

Hello

I am researching to find a way to have a collection of 2d images from a single 3d .stl object in order to use that collection of 2d images for training a machine learning model.

- first : can i use the 3Dslicer as an API service , which means my app sends the stl image to the service and in return get the result as a collection of 2d images ? ( slices of the 3d object )
- even 2d images from different angles would be solution . ( 20 images from different angles )

tnx

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [November 1, 2020, 7:27pm UTC](https://discourse.slicer.org/t/using-slicer-via-web-service-api/14368/3 "2020-11-01T19:27:26Z")

</div>

Since you can use any Python packages in Slicer, it is relatively easy to expose any features via web services. See an example here: [https://github.com/pieper/SlicerWeb](https://github.com/pieper/SlicerWeb).
