See full event listing

Automating Image Workflows with Photoshop APIs

Raymond will introduce and explain how to use the Photoshop REST APIs to build image automation workflows, everything from powerful AI enhanced filters to text editing of PSD assets.

Raymond Camden is a Senior Developer Evangelist for Adobe. He works on the Document Services APIs to build powerful (and typically cat-related) PDF demos. He is the author of multiple books on web development and has been actively blogging and presenting for almost twenty years.

Raymond can be reached at his blog, @raymondcamden on Twitter, or via email at


Raymond Camden 6:18
Absolutely. Thank you so much. And I want to quickly go back to the session, you’re talking about forums. I love forums, back when HTML five was a big deal. And like every conference had 20 html5 sessions. Every single html5 session I would sit in was all look at Canvas. And we could draw pictures and stuff like that. And no one was talking about improvements to forums, which every web app that I built for 20 years has used formfields. So every time something happens, a forms in terms of new types of form fields, or new CSS abilities to style forms, I get super excited because like, literally every single web out there has a form of some type. So that that upcoming section sounds really, really cool. So anyway, we’re talking about Photoshop not forms. I am Raymond Camden, I am a developer evangelist for Adobe, I mainly work with our document API, so everything involving going to and from PDFs and working with PDFs. But I’ve recently been doing a lot of work with our Photoshop API’s as well. If you need to ask me a question about anything I’m talking about today. I know Brian’s going to be collecting questions, what if I miss it, or if you think about it later, you could hit me up at my blog, On my blog, I do have a link to my Mastodon, I’m on Bluesky as well, but I’ve no idea what my profile is. And you could also email me at work where I am And I’m still shocked that nobody else thought to get that alias. I’m probably the coolest person at Adobe. Maybe. So what are we talking about?

Raymond Camden 8:08
Today, talking about the Adobe Photoshop API. This is a automation process automation thing that works with Photoshop and Lightroom. It is a set of REST based API’s, which means you’re free to use whatever platform you want to. So PHP, node, JS, ColdFusion, dotnet, etc. There is a node SDK and development, I am more comfortable with our rest API’s. They’re pretty easy. Hopefully, you’ll you’ll see that as I show you code. But there is a SDK that’s being worked on. And I have somewhere later in the presentation, I do have an example of that. Excuse me. So one thing to keep in mind is Photoshop experience is not required, thank God because I don’t really know how to use it. I had to open it a few times to make a few demos. And it’s an amazing tool that I have very little experience with. But that is okay. So if you are the developer for your company, and you are looking to do automation, based on these API’s, you can absolutely work with somebody who has Photoshop experience. You do not need to know much of anything really to do in effect. The only reason I even open Photoshop normally is to make a sample file to use for a demo, so it’s definitely not part of my day to day. If you do know it, I will certainly be helpful, but don’t worry about having a lot or any experience with Photoshop. So I always like to start off with the cost that way you can know what to expect. There is a free trial And that is 500 API calls, there is no distinction between one type of API call versus another. I only bring that up. Because on my main team Document Services, we do have some API’s that are a bit more expensive in terms of their usage. But for these API’s, just one call, is just one cost. Again, free trial, you don’t need to use a credit card or anything like that you could sign up. If you are a small business, you can get a raw cost via AWS 15 cents per call. And if you need something that’s a bit higher than that, good news, Adobe has plenty of salespeople who will happily work with you to find a great deal. And I’m kind of joking about that. But honestly, yes, you know, they, they, they want people to use this product, so they will work with you. So you have a couple of different options in terms of what you could do. But most importantly, if you’re watching a recording of this later on, make sure that we include a link to the slide deck, you can, you can click this particular link and see the latest pricing information for the API’s. So in terms of the current list of features, I am not going to read from the slides. And so I’m just going to dump a bunch of text on there for you. I will say that, even though I call these the Photoshop API’s, and that’s kind of the marketing term for it. There are Lightroom API’s as well. Honestly, to me, it’s all I need to do X with an image, I don’t really mentally think of Photoshop versus Lightroom. But definitely, if you’ve used these products, you know how they differ. So again, I’m not going to read from the list of texts on there. But I do want to point one thing out. So I, again, not a Photoshop user. But even without being a user, I know about Photoshop actions, it’s a way to record a set of operations against a particular image, so that you can repeat it again and again, well, we actually have an API for that, which means you can create this kind of complex process, use it via the API, and then automate that, even better. And I just found out about this a few months ago, there’s a way to create a Photoshop action in JSON. And once you have it in JSON, and you could use that via our API, once you have it in JSON, then you can actually manipulate it. So if you have this 10 step process, where if the image has a lot of red stuff in it, you want to skip a step. Because it’s JSON, it’s just pure data, you can actually skip that when you call the API. Also, for actions that are numerical based, so let’s say how much you blur an image, again, programmatically, you can modify that JSON before you call the API to actually create, you know, really dynamic photoshop actions, which I think is really, really, really cool. I’ll also say things like remove background and image mask involve quite a bit of AI. And they will work really, really well. Typically, like we’re not saying that in the past, I’ve seen a user in Photoshop, selecting the background manually, the API is going to automate all that for you.

Raymond Camden 13:33
So let’s talk about the why, as my cat decides to make some noise behind me, I have a cat on screen. So that works out just fine. Surely, she won’t do it again now. So to get started, you will need some credentials, you definitely need an Adobe ID. And if you’ve done anything on Adobe at all, then you already have an existing ID. Like I said earlier, you do not need a credit card to do the free trial, which is great. And then we provide a signup form. I’m not going to click on this, I’ll just show you a couple of screenshots. But, you know, we asked for the basic type information, you are asked you know why you want to get the free trial. After you do this, you’ll be asked to create a project, all of the developer related stuff at Adobe use projects. It’s a way of grouping your API’s and your credentials. So the Photoshop API was going to walk you through that process of creating that project and adding the credentials. At the end, you will be given your credentials and I believe it also downloads automatically so you can immediately begin working with it. However, big giant red flag and all this depends on when you’re watching this. So if you are really excited about what I’m showing you right now, and like as soon as I’m done, you go sign up If this applies to you, if you’re watching this a few weeks in the future, it won’t apply, I’d say one or two weeks from now. So about four months or so ago, Adobe, like globally, made a change to how credentials work with all of their API’s. They went from a JWT-based credential system, to an OAuth-based credential system. What happened is that not all the products, were immediately ready to start generating those new credentials. So that impacted Document Services. For example, the API is work fine with the JWT or the OAuth. But the wizard, for example, that you saw that you sign up with and start off with, will still generate the older JW T credentials. And I bring that up, because if you go into your developer Council, you’ll get this big scary red warning about how you don’t eat enough vegetables don’t exercise, and are using deprecated JWT credentials, those deprecated credentials will work until January 2025. So not even the January, that’s four or five months from now, but like a whole year past that. And the council will actually very nicely kind of walk you through migrating to the OAuth credentials. So I hope I haven’t scared you off yet. Again, the web based kind of nice walkthrough to get that free trial is going to be updated in two weeks. If you do it right now, you can still migrate very, very easily. And this link here, it goes to a blog post that I wrote, that talks about that change and authentication, and you know, a month or two from now, I won’t need this slide anymore, and we won’t have to worry about it. But I will say I will be using the newer OAuth credentials and all of my code. So if you’re watching this 10 years in the future, it will still work, you know, assuming we’re all still here.

Raymond Camden 17:05
So first thing you want to do when once you have your OAuth credentials is actually check to make sure that access works. So to get that working, we’re going to convert a client ID and a client secret, because that’s all we get with the OAuth credentials to a access token, and like I said, reusing the new o off server to server creds, this can all be done in one API call. And let me actually show you how complex that is. So I have a function here, I’m using Node js. And again, this is a REST based API. So you can use whatever platform you want to. And basically, I’m going to scroll up a little bit, I’m grabbing my credentials via environment variables. In this case, I’m actually storing them in a dot env file, I want to click on it so bad to show you, I won’t click on it. So my credentials aren’t on the video. But I’m going to hit basically a global Adobe login, you can see it right here. Our Doc’s will have this information as well, pass in my client ID has been my client secret. And then I will look at the response. So let’s open up terminal. And we will node generate access token that MJS. And I get a giant access token with also an expires, I will go ahead and minimize that. So you don’t copy and paste it. If you’re able to copy all those characters down in five seconds, I’m really, really impressed. But that is basically what you would do for authentication. After that, the next thing you can do, and this was going to be option is hit the Hello endpoint. And again, this was not required. But this is something that the Photoshop team did that I wish more API’s would would do out there. So the Photoshop API’s are going to be a little bit complex, you know, you’re working with input files, you’re generating output files, you’re working with binary data. So testing typically means a little bit of prep work, like I need to create an image that’s going to be my input. That’s nothing wrong with that. That’s just the nature of this particular set of API’s. So what they did is they made an endpoint that is just there for checking your credentials, and they call it the Hello endpoint. And I’m seeing that nice, giant glaring typo there that I will fix as soon as the session is done. So that code looks like so. So one thing I’ve done I’ve gone ahead and I’ve moved the access token logic into a function. I just collapsed there. But this is the exact same code that I showed you before. And now I’m going to get my access token. And then I’m going to hit this hello endpoint, it’s going to return text not even JSON. But what’s nice is that I can confirm that my credentials are working correctly. And I’ve generated the access token, right? So if I do node say, Hello, I should get Welcome to the Photoshop API. Yeah, again, I really, really dig that. And I wish that more API’s that deal with binary data and files and such, would consider an endpoint like this to help you confirm that you’ve set up your authentication correctly. But again, you don’t necessarily need to do that. But I, when I’m learning something, I always take baby steps like I could do every single small step possible to ensure I don’t screw up too bad. So the next thing that you have to start thinking about is storage. And why do we think about storage is because all of these API endpoints will only work with remote files. So I’m doing all of my demos on my local desktop here, I have no JS scripts locally. However, the API currently only works with remote files. And by that we mean, for example, s3 on AWS, Google Drive, Azure, Dropbox. And on top of that, if you have a public URL for your input, like it’s a image that’s under a URL that doesn’t need a login, you can just pass that and then the API is fine with them. And if you really wanted to, if you want to set up your own server, you can craft your own endpoint and give it to the API, the Photoshop API, when it’s done its work, it will send that binary data to that writable URL. And if you have a server up and running, then you can process it. So you can do that. Generally, I recommend to sticking to one of the cloud providers listed above. For this presentation, except for one small demo, I’m going to be using AWS three. Just remember though, that everything that I’m showing will work elsewhere.

Raymond Camden 22:09
Alright, code time. Let’s talk about how the API flow works. So you will start off by figuring out what your input URL or URLs are. And again, that’s going to depend on where you’re storing those files. All the cloud providers that I mentioned, have their own particular way of generating a readable URL. Conversely, you also need to create a output URL or URL, some of these endpoints can take one or multiple files. And some of these API features can output one or more files, you will then create your JSON body and that’s going to be based on the API documentation. And you will then simply pass that to the endpoint. So you’re never sending binary data, you’re only sending the URLs and the JSON call. So it’s always gonna be pretty quick. But then you’ll pass that to the endpoint. This is either going to give you an error, if you screwed up, or is going to give you a job URL, you can then optionally poll to see if that’s done. There are many times where you may not care. You know, if there was no error creating the job, and you expect the API to work perfectly, you can just assume that it worked correctly. Typically, you’re probably going to pull for a response. However, because we give you that job URL back, you can have a whole separate process that runs in a different environment even and it just has a queue of URLs that will check, see how things turned out and potentially send an email or ring someone’s pager if something went wrong. And then you just repeat profit, etc. So here’s an example of just one of those JSON bodies. In this case, it’s for the remove background call. It has the input, it has options. In this case, it’s pretty limited. And the dots will tell you more about it. And other API endpoints, obviously, we’ll have more more choices for what options you pass. And then for output, again, passing a URL, and then a few other particular options that will depend on that particular call. I will just show you the API reference, we won’t be using it a lot. But this is where I got it from. And it’s all very clear. I can also say, I find that the errors from this API are really well done. So like where, for example, I pass a bad value to a particular key. It’s very clear that hey, this key is wrong. If I don’t include a particular value again, The errors that I have seen had been really, really nicely clear. In fact, for my next time given this presentation, I’ll probably go ahead and make a demo that intentionally shows an error. So y’all can see what that looks like. Oops, get back up here. So for my first example, I am going to use a file up in a AWS S3 bucket. And in this case, I’m going to use dogs dot jpg. And that’s what it looks like you can clearly see two dogs looking very, very attentive at something, and then a background behind them. So what we want to do is actually use the Remove Background API to modify this source. So let’s look at the code for that. And I will just kind of slowly walk you through this bit by bit. So I am using S3 like I’ve mentioned more than once, and S3 and AWS, they have their own SDK. So all I’ve done here in the first, let’s say, three lines or so is imported from S3, what I need to work with s3, I’ve done things like specify my region and my particular bucket. And to make it easier, I created two utility functions, that will create a readable URL for me, I call it get sign download URL, as well as a signed upload URL that will allow me to put information. So again, if you are using something like Dropbox or Azure, you can imagine having probably the exact same functions, just different code inside them to handle that particular platform, I still have my get access token, which I’ve minimized here. And if we look at the code, now, I’m going to get my access token that’s on line 44, I’m gonna go ahead and ask S3 or the SDK to create a URL for my input, and one for my output. And then I’m going to craft my JSON. And you can see here, it’s mostly hard coded except for input and output. And then I am just going to call the API endpoint. And that said, I’m gonna go ahead and dump out the response. In theory, he should actually check the result, make sure it happened. But I’m sure nothing possibly can go wrong with that. So we run it move BG, we will see it runs and immediately gives me a job.

Raymond Camden 27:49
So it is extremely quick. To be clear, this is just starting the job. But because I’m not sending the binary data, I’m just sending a JSON body a small one at that, I very quickly get the result back this particular URL, we’re going to use in a few minutes, and see how you can work with it and check how it is going. But the result, and this is obviously static in my presentation, but it does work, I got it from the API call, you can see it very nicely removed every part of the background from it. And I didn’t have to specify anything at all, this is going to be aI driven, it’s not going to be perfect. But for doing this at scale, if it works well most of the time, and I could manually check later, this is saving a heck of a lot of work, an incredible amount of work. So I did mention that we should probably you know, look at the status, you know, see how it’s running, just ensure that nothing has gone wrong. That would be done via polling. I’m gonna be doing this in one script. But you could have multiple scripts, one script to start a process and one that handles checking to see how things are going. So you take the result of that job creation, you will pull at whatever interval makes sense, I would not do it instantaneously, I would definitely add some kind of delay in there. And then wait for the status to be either succeeded or failed. So let’s take a look at that. And all I’ve done here, let me minimize this and get this back here. But it’s the same code as before. You see my S3 code on top, my access token, I minimize that. I did take the API call and make a function out of it called make BG job. And you see it’s going to return the result from that API call. I’ve added a little you Todi function, it’s lame, but it works, that handles doing a delay. And then here is now the meat of my code. So get my access token, generate an input and an output or upload URL, and then make the call to the endpoint, and then work with the result, I then have a while loop, that’s going to call that job URL, you do have to authenticate it like other calls. And you see I’m doing it there by passing in my access token, and then look at the result. And then just repeat, I added a delay of a one second, you could use two seconds or three seconds. It’s really fast. So I think once I can feels right, I run remove BG poll, we can see it in action. And there you go, it took three seconds, if you’re curious. And let’s actually do this, let’s actually do a dump of the entire result of that poll job. So you can see what it looks like. And this will flood the screen a little bit, but we’ll try to pick just one. All right, well, let it finish. So let me make this a little bigger. And you can see all right, here’s one job. So you can see the status created, etc, the input URLs, metadata, etc. So you do get more than just the status. So you have more data that you can work with, if you want, or not, it all depends on what you’ll be doing with the service.

Raymond Camden 31:44
Let’s talk about more of a real use case, I think that there’s somebody that probably some of you have come across, where you will create kind of like a stock ad kind of basic ad with some lorem ipsum text in there. And then before a big sale, maybe a day, maybe an hour before it goes live, all the people who have to sign off on this particular ad, they’ll finally come to an agreement. I have worked at some companies where process was spelled with a capital P and 900, people had to sign off on suddenly before anything happens. So you may work at one of those companies as well. So you can imagine like the very, very, very last second, this text comes in, and then you need to generate the final version of that. And of course, as soon as you do, they’ll come in and with tweak texts, or even better, they’ll say oh, by the way, we also need this in multiple different languages. And again, probably they will change it after they give it to you and you do the work. So normally, this would involve like, you know, going in Photoshop and taking that base add image and that text layer. And you can see up here lorem ipsum. And then manually editing that text and doing File, Save As or File, Export, etc. But instead, we want to automate that. So for that, we’re going to use the Edit Text Layer API, this is what that body will look like. It’s slightly different than the previous one and put his now in array not as singular value. And under Options, I need to specify the text layer or text layers that I want to change and the new text. Now this particular endpoint is actually really complex. If I scroll down to Options, I hope that you could see us on the right here, there’s options for fonts and the layers and all that and it gets gets really, really complex. But if you literally just want to change the text as is, then that’s really all you have to do. I’m going to save this as a JPEG. So let’s look at some code. And we’ll look at two versions of this post. There we go. All right. So let me scroll back up again. So I again, I’m going to be using S3. So I have a bunch of code upfront to handle setting those defaults. Again, I have all of my utility functions. And let’s go ahead and minimize all these. We don’t need any of these don’t need to see delay. I took that polling logic. And I also moved that into a simple function that I could call a call poll job. And then I made a new function that looks a lot like that previous one, except I’m calling it make text edit job where I pass in an access token, my input and output URLs, and then the text. Again, this particular API endpoint has a lot of options. I had said I only knew to worry about the texts. So my you know, function, blueprint etc is rather simple. In this case, we’re at Texas, the the the main thing I care about. So if we go down to the main just, you know the actual main body, it’s actually really kind of short. Now again, get that input URL, I’m working with a PSD file, so an actual Photoshop file. And that’s the same one that I showed on the slide, but a minute or so ago. And then I’ll be saving it to this case, test underscore txt dot jpg, I have generated my texts, and this is hard coded, but you can imagine it being dynamic, I create the job, I pull the job, and then I will look at the final result.

Raymond Camden 35:50
So if we run this is edit text later that MJS it should fire off the event and then return that big ol JSON thing. But all they really care about is the fact that it succeeded. Let’s make it a little bit more complex, because that was too easy. What if instead of one set of text input, I have three, I have German and Spanish and English. So in this case, I have created an array, where I’ll specify the file for each one, I’m using a language code or country code at the end to signify it. And then passing different texts. For each of the three options. I use Google and my son to help with his translation. So if you’re sending mistakes, blame me, not my son, Photoshop, etc. And then all I do is simply call this in a loop. By the way, for async code, I would typically not do a for loop like this, because this will run one after the other, I would make a lot more sense to create all three jobs at once, do all three polling at once, use that promise that all or not any excetera to to handle that at a more synchronous, I’m sorry, asynchronous fashion, I was going for simplicity. And look at me, I even put a comment saying that. So I would not forget. So again, just keep that in mind. If I was doing 50 translations, and also potentially outputting different sized ad material, I could have maybe 100 or so different jobs out there, I could definitely do this a lot faster, and not in the one by one fashion that you see there. And I will run this again, this is just added layer to take some water.

Raymond Camden 37:50
And they excuse me, they all output. And the result is what you expect. So the image of texts, and then the Spanish and then the German version. So that was automation. But with like me running it manually. I do have a couple of examples on our developer blog that you can look at when using power automate. And when using Pipe Dream, which is a fun little low code solution. I want to show you quickly what the power automate version looks like. Because I really dig power automate. Let me get into this flow here. So I created a basic power automate flow that works with Azure Blob Storage, not S3, where I can upload to and Azure Blob, it will automatically run this power automate flow. And it’s going to do a couple things. So first thing that’s going to do these two steps here, hopefully can see my cursor, okay? This is where I’m working with my secrets, my client ID, my clients secret power, automate does have a nicer way of doing this, but I just kind of hard coded them in there. Then within Power automate, I was actually able to say, Hey, give me a readable file, I’m sorry, a readable URL for that file that was just uploaded. And I then essentially do kind of the sense that I didn’t know Jas. So I will make a HTTP call a post to get my access token and I passed in my two variables. This gives me a JSON back that in power Automate, you have to have a different step to parse. And then I created a output URL, essentially a writable URL using Azure to give me a URL that was saved for uploads. That part’s a little complex. I’m going to kind of gloss over a little bit, but the last step was basically then to call the Lightroom eight py, and pass in another JSON object. So I have my input, I have my output. And I will show you an example of this actually running. And it checks. When I upload a file, it checks, I think, every five minutes or so. And I really don’t want to wait for five minutes. So I’m gonna go in here and do edit. And I’m gonna do tests, I’m gonna do tests manually. And then I’m going to go into my Azure Blob, desktop client that Microsoft kindly provided. And we’re going to upload, let me bring this over here real quick get to my source file. Where did I put it? First up, API prezzo. Alright, so I have a image called Good source image, I did that just because I knew that I’d be presenting and would forget, if we double click, you could see it’s a lovely picture may be a little dark. But I’m gonna go ahead, I’m gonna drop this into my Azure Blob should upload automatically. And there it is good source image, it’s going to write to PS API out. Let’s see if it’s fired yet. And it did. So actually, it should be already done. Let me refresh Azure, there it is. Double click. And we should get the result. And I may not make it clear, this was using the Lightroom Auto Tone. And you could see this is my input, it’s dark, the output is definitely a heck of a lot clearer. And surely, you know, a photo expert could probably do more to this to make it even better, make it suit your particular publication needs, whatever. But you can imagine if you’re getting like millions of photos a day, being able to automate this particular process of making them better, can can definitely save you a lot of time. So again, I linked to in the presentation, a article that explains the entire power automate flow, I have a similar one for a pipe dream, if you want to use that. I will also say I mentioned the SDK, you can absolutely write a Amazon lambda to work with the push API. This is an example of what the SDK looks like. It’s pretty simple. So generate input and output URLs. And really, we have a client, that’s the SDK, we admit it. And then we just call create, Creek cut out. And this runs it. Again, I personally prefer the rest API’s. But this SDK does make it even a little bit simpler. So keep an eye on that. In terms of resources, I linked to everything, including the docs on this guy show you what that looks like. linked to the REST API reference, we do have support forums, and people do check them to make sure that you do to to help you if you need it. There is that node SDK that you can use in development. Right now, I believe it is s3 only. But that’s not going to be the case once it’s done. And then I have a link to this entire slide deck and the demos that I showed to date. Who So Brian, if there are any questions, I am available to answer those questions. Don’t ask me about Firefly though.

Brian Rinaldi 43:52
Oh, so okay. I was gonna ask you about Firefly. No kidding. I wasn’t. That was awesome. Yeah. So I mean, I’m not a an image expert like you. But But yeah, I mean, that, that all seem pretty easy to just kind of, you know, pretty straightforward. I mean, obviously, as I mentioned in the comments, I’m like, I don’t think your your company branding would approve of your ad design. They’re like, you’re right. Arial text on. But But I mean, you know, you can get as fancy as you want, based on what you showed.

Raymond Camden 44:31
Absolutely. And you can. So I mentioned that that, that the Edit Text Layer API was really complex if you needed it. You can change fonts. So like, for example, if Spanish, if it made sense to have a different font and Spanish because Spanish, then you can do stuff like that.

Brian Rinaldi 44:50
So, of course first of all, do you have the links, folks already want the links to the files and presents He can be posted in the private chat. I’ll go ahead and post it on…

Raymond Camden 45:04
I’m trying to figure out how to do that without showing it on screen. Right. You’re not sharing my screen.

Brian Rinaldi 45:08
I’m not sharing your screen. So your grades were good. Yeah. So I will paste that for you, Joshua, and for anyone watching on YouTube as well. And then, so I have a, okay, this may be like, kind of a silly question. But no silly question. So, so if I’m just testing stuff out, like, I’m assuming that each of those each of those API calls to like, when I’m polling like that, all of that counts against my 500.

Raymond Camden 45:41
I am 99% Sure, it does not count. And so I’m gonna go with that. But I will verify. But if you don’t hear back from me, then then know that it does not count. I 99 point in Hybris. Ensure that they only care about the actual jobs, you’re creating, not checking the status of your job.

Brian Rinaldi 46:00
Okay. So okay, so it’s, it’s fine. It’s essentially like 500 jobs.

Raymond Camden 46:06
Yeah. 500 things? Yeah.

Brian Rinaldi 46:09
Okay. All right. That’s, that’s really cool. And so like, let me I didn’t see you show it. But I’m assuming maybe you mentioned it, and I, and I missed it. But like, I know, a common thing is like, oh, user uploads profile image of some sort. And I want to crop it to like fit the size, maybe like, or, or any kind of image user uploaded image that I want to crop it to the content on the image like, oh, you know, they upload a picture of themselves, but I want to crop it to the actual person without the background. Is there? Is there an option for that?

Raymond Camden 46:47
No. So I know another company that can look at a photo and figure out the most important thing and crop to it. I don’t believe we have that. If you knew we’re, if you knew where the base was. And Microsoft actually has an API for that, you’ll give it a picture. And I’ll tell you like x and y, and z naught z, they’ll give you box coordinates for a face. So you could combine that together. That type of thing.

Brian Rinaldi 47:15
Okay, okay. So like you could, I mean, I guess most of most of the clouds have some kind of service like that for face detection. Right. So, so you’d have to use a combination of face detection and, or some kind of okay. All right, that’s cool. I think I know who you’re talking about, is the other person, other company that does that, but I won’t mention them, because I won’t get you in trouble or anything. So that’s cool. And what so like, what are what are? What are some, like some of the other? And he didn’t talk about, but like, what are some of the other options for like, for image editing that you like I can do, you know, besides like, the cropping, I mean, and the displaying of text? So that’s actually let me get back to sorry, that the spelling of text, you’re actually editing a Photoshop file with layers, right? It’s not it’s not a like a or is it an image? Or is it a JPEG that I’m adding layers? Can I actually upload like, say, cloud storage of Photoshop file of some sort that I actually modify layers? Or is it is it?

Raymond Camden 48:21
Yeah, a lot of find your file like your, for that text edit example, I gave it a link to my PSD, that was a read only link. So it grabbed the PSD, and made the changes to the layer that generated the output generated the rendition. And that it’s not going to modify your source template, you may be able to say input as x and output is x and override, and that would do so but I would hesitate.

Brian Rinaldi 48:50
I guess I was I was more like, that’s a Photoshop file. So like, I could actually, like a designer could design that file and like so that this, like, the text has a particular that layer where the text is already styled and placed, and I’m just editing that layer, right? So I mean, give it all the options for styling.

Raymond Camden 49:14
Yeah, I did that there’s definitely more options for styling, I only changed the test content. So you can imagine the human being the PSE double clicking on the layer and typing new crap in. That’s the simplest. So it’s it’s easiest to demo, you can do more complex stuff. And I believe you can easily resize the layer a bit to give them more room which I could see making sense for like German because they definitely need more room for texts. You can you can do much more than just changing the actual text content.

Brian Rinaldi 49:46
Right. Okay. Well, very cool. So because it’s a Photoshop file, it’s going to maintain all the all the existing design that we have set up and stuff

Raymond Camden 49:56
and I spit out the exact same images same box you can definitely imagine banner ads square instead of letterbox shape. You can do multiple renditions, again, all automated without having to open up Photoshop.

Brian Rinaldi 50:15
Now, since it’s all job based, it’s my final question. So it’s all job based. I can’t necessarily like, you know, there’s some services and I won’t name names against where I could just basically pass a bunch of parameters and say, like, give me image x with like size to this kind of thing. And it basically serves me up that. So I could use that on my site as like the source of my image file. Instead of generate, like generating the new image via an API call, there’s not like a way to just say, hit a URL and get the image back.

Raymond Camden 50:54
No. It’s just gonna be a REST API. Now you can, a company I will mention Cloudflare. I know that there’s serverless support, tied with their web app hosting support, you can map your else to functions. So in theory, it would be possible to map particular URL patterns to a worker worker makes use of the flush up API, you would need to do your own kind of caching like Have I already made this image before. So it’d be possible to build something like that yourself.

Brian Rinaldi 51:32
Rachel’s in the audience saying she’s trying to be good. She happens to work for the company, which you were choosing not to name right now. So thanks, Rachel. All right, folks. I unless anybody else has any other questions for Ray, I did post the resources there. I think there’s a lot to check out. It looks it looks really cool.

Transcribed by


More Awesome Sessions