{"id":1897,"date":"2018-09-17T16:24:04","date_gmt":"2018-09-17T16:24:04","guid":{"rendered":"http:\/\/www.aqbsolutions.com\/?p=1897"},"modified":"2025-04-18T06:09:39","modified_gmt":"2025-04-18T06:09:39","slug":"invoke-a-lambda-from-another-lambda","status":"publish","type":"post","link":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/","title":{"rendered":"Invoke a Lambda from another Lambda"},"content":{"rendered":"<p>In the past series of articles on AWS Lambda, you have seen the following :<\/p>\n<ul>\n<li>How to set up Lambda on Amazon using Python<\/li>\n<li>How to use your Lambda function to call your External API<\/li>\n<li>How to call your Lambda function from a PHP application launched on an EC2 instance.<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-large wp-image-6120\" src=\"http:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-1024x991.png\" alt=\"Articles on AWS Lambda\" width=\"1024\" height=\"991\" srcset=\"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-1024x991.png 1024w, https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-300x290.png 300w, https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-768x744.png 768w, https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-1000x968.png 1000w, https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-230x223.png 230w, https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-350x339.png 350w, https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda-480x465.png 480w, https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Articles-on-AWS-Lambda.png 1101w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/p>\n<p>In this article, you will see how a lambda function can be called from another lambda function.<\/p>\n<p>You will also see some use cases which illustrate the reasons for calling a lambda from another lambda.<\/p>\n<p><strong><b>Use cases where you call one lambda from another lambda<\/b><\/strong><\/p>\n<p>There are several occasions when you would like to do some tasks, by calling one lambda from another. Some of the use cases in which a lambda function can be used to call another lambda function are explained below:<\/p>\n<p>Use Case 1: Using a Cron Lambda to call another lambda that does some job<\/p>\n<p>There are use cases where you may want to set up one Lambda function as a cron task. This lambda function, in turn, could launch multiple instances of another lambda function that does some job.<\/p>\n<p>Now, in this particular use case, we can also have one cron lambda function that is used to fire a non-lambda function, multiple times. However, in this case, the limitation is that the non-lambda function that performs the action cannot be consumed by other clients.<\/p>\n<p>If, however, you use a cron lambda to call another lambda function to do the job, you could also allow other clients to call\/invoke the action lambda.<\/p>\n<p><strong><b>Use case 2 <\/b><\/strong>: Dividing large jobs into multiple lambdas<\/p>\n<p>AWS Lambda service comes with a number of limitations which can be kept in mind while architecting good solutions.<\/p>\n<p>For instance, there are some hard limitations for the runtime environment; the disk space is limited to 512 MB, memory can vary from 128 MB to 1536 MB, and the execution timeout for a function can be maximized in 5 minutes.<\/p>\n<p>Thus, due to the size and runtime restrictions imposed on Lambda\u2019s, large jobs can be divided into multiple lambdas where one lambda function could be used to call another lambda function.<\/p>\n<p><strong><b>Steps that illustrate how a Lambda can be used to invoke another Lambda<\/b><\/strong><\/p>\n<p>Let us now see how we can call one lambda from another lambda.<\/p>\n<p><strong><b>Step 1: Configure your role so that a lambda function can use it to call another lambda<\/b><\/strong><\/p>\n<p>While<strong><b>\u00a0<\/b><\/strong>writing a Lambda function the invokes another lambda, you will need a Role that is configured with the required policies that allow the invocation of another lambda.<\/p>\n<p>In this case, the role to which the policies are attached is <strong><b>lambda_basic_execution. <\/b><\/strong>You can, however, create your own roles and attach the required policies as shown below.<\/p>\n<p>Login to the <strong><b>AWS Management console<\/b><\/strong>\u00a0and Choose <strong><b>IAM<\/b><\/strong>\u00a0option under <strong><b>Security, Identity &amp; Compliance<\/b><\/strong>. This will take you to the \u201c<strong><b>Welcome to identity and Access Management<\/b><\/strong>\u201d page.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2128\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0011-1024x498-800x389.png\" alt=\"\" width=\"800\" height=\"389\" \/><\/p>\n<p>In this page Click on <strong><b>Roles<\/b><\/strong>. This will take you to a page which allows you to create a new role or search for an existing role.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2130\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0021.gif\" alt=\"\" width=\"665\" height=\"324\" \/><\/p>\n<p>If you want to create a new role and attach required policies to it, then click on <strong><b>Create role<\/b><\/strong>\u00a0button and continue further by attaching the required policies to it . In this case, however, we would be using the existing role i.e \u201c <strong><b>lambda_basic_execution\u201d.<\/b><\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2131\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0032-1024x459-800x359.png\" alt=\"\" width=\"800\" height=\"359\" \/><\/p>\n<p>If you want to create a new role and attach required policies to it, then click on <strong><b>Create role<\/b><\/strong>\u00a0button and continue further by attaching the required policies to it . In this case, however, we would be using the existing role i.e \u201c <strong><b>lambda_basic_execution\u201d.<\/b><\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2132\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0052-1024x459-800x359.png\" alt=\"\" width=\"800\" height=\"359\" \/><\/p>\n<p><strong><b>\u00a0<\/b><\/strong><\/p>\n<p>You need to ensure that \u00a0your role , <strong><b>lambda_basic_execution <\/b><\/strong>role<strong><b>\u00a0<\/b><\/strong>must have the<strong><b>\u00a0AWS Lambda Role <\/b><\/strong>policy attached to it as shown below. This policy allows the lambda function to invoke another lambda function.<\/p>\n<p>If your lambda function does not use S3 you need not use <strong><b>AWS Lambda Execute<\/b><\/strong>\u00a0policy.<\/p>\n<p><strong><b>AWS Lambda Basic Execution Role<\/b><\/strong>\u00a0policy grants permissions including permissions for Amazon cloud watch actions that your lambda function needs.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2133\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0072-1024x498-800x389.png\" alt=\"\" width=\"800\" height=\"389\" \/><\/p>\n<p><strong><b>Step 2: Create a Lambda function that calls another lambda<\/b><\/strong><\/p>\n<p>In this step, you will see how a lambda function can be created that invokes another lambda function can be created.<\/p>\n<p>In the <strong><b>Services menu, c<\/b><\/strong>lick on <strong><b>Lambda <\/b><\/strong>in the<strong><b>\u00a0Compute <\/b><\/strong>section<strong><b>. <\/b><\/strong>This<strong><b>\u00a0<\/b><\/strong>will take you to a page that allows you to create a lambda function and search for existing lambda functions.<\/p>\n<p>In this page, click on <strong><b>Create function<\/b><\/strong>\u00a0button, to start creating a new lambda function.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2134\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0091-1024x498-800x389.png\" alt=\"\" width=\"800\" height=\"389\" \/><\/p>\n<p>This page allows you to provide a name for your Lambda function, choose your coding language, and choose a role that defines permissions for our function.<\/p>\n<p>In this case, we have provided the name of the lambda function as <strong><b>call_lambda_lambda<\/b><\/strong>, used <strong><b>Python 3.6<\/b><\/strong>\u00a0as the coding language, and used an existing role i.e \u00a0<strong><b>lambda_basic_execution<\/b><\/strong>\u00a0which contained the required permissions to invoke another lambda.<\/p>\n<p>Click on <strong><b>Create<\/b><\/strong>\u00a0<strong><b>function <\/b><\/strong>button to successfully create your lambda function, as shown below.<\/p>\n<p><strong><b>\u00a0<\/b><\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2135\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0111-1024x459-800x359.png\" alt=\"\" width=\"800\" height=\"359\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2136\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0131-1024x459-800x359.png\" alt=\"\" width=\"800\" height=\"359\" \/><\/p>\n<p>In the <strong><b>Function Code<\/b><\/strong>\u00a0section, you can write code for your lambda function that invokes another lambda function.<\/p>\n<p><strong><b>Code :<\/b><\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2137\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0151-1024x498-800x389.png\" alt=\"\" width=\"800\" height=\"389\" \/><\/p>\n<p><strong><b>Code : call_lambda_lambda<\/b><\/strong><strong><b><br \/>\n<\/b><\/strong>The following code shows the code written for <strong><b>call_lambda_lambda<\/b><\/strong>\u00a0function that calls <strong><b>api call <\/b><\/strong>function<strong><b>.<\/b><\/strong><\/p>\n<pre>[source language=\"code\"]#import libraries import boto3 import json def lambda_handler(event, context): #Define object of lambda #Here service name is lambda and the region_name is the name of the region where the called function \"api call\" resides invoke Lam = boto3.client(\"lambda\",region_name=\"us-east-1\") #Define a payload that needs to be passed with a message payload = {\"message\": \"Hi, You have been invoked\"} #Call the lambda function \"apical\" by using the invoke method of the invokeLam object resp = invoke Lam.invoke(Function Name=\"apical\", Invocation Type=\"Event\", Payload=json.dumps(payload)) #resp = invoke Lam.invoke(Function Name=\"apical\", Invocation Type=\"Request Response\", Payload=json.dumps(payload)) print(resp) return \"hello from lambda\"[\/source code]\n\n&amp;nbsp;\n\n&lt;strong&gt;&lt;em&gt;&lt;b&gt;&lt;i&gt;In the above code, if you use the Event(asynchronous ) invocation option, the function will be invoked at least once in repose to an event, and the function must be idempotent to handle this.&lt;\/i&gt;&lt;\/b&gt;&lt;\/em&gt;&lt;\/strong&gt;\n\n&lt;strong&gt;&lt;em&gt;&lt;b&gt;&lt;i&gt;\u00a0&lt;\/i&gt;&lt;\/b&gt;&lt;\/em&gt;&lt;\/strong&gt;\n\n&lt;strong&gt;&lt;em&gt;&lt;b&gt;&lt;i&gt;If, however, you use the Request Response(synchronous) invocation option, the function will be invoked only once.&lt;\/i&gt;&lt;\/b&gt;&lt;\/em&gt;&lt;\/strong&gt;\n\n&lt;strong&gt;&lt;em&gt;&lt;b&gt;&lt;i&gt;\u00a0&lt;\/i&gt;&lt;\/b&gt;&lt;\/em&gt;&lt;\/strong&gt;\n\n&lt;strong&gt;&lt;b&gt;Code : apical&lt;\/b&gt;&lt;\/strong&gt;<\/pre>\n<p>The following code shows the code written for\u00a0<strong><b>call_lambda_lambda<\/b><\/strong>\u00a0function that calls\u00a0<strong><b>api call\u00a0<\/b><\/strong>function<strong><b>.<\/b><\/strong><\/p>\n<p>#import libraries import boto3 import json def lambda_handler(event, context): #Define object of lambda #Here service name is lambda and the region_name is the name of the region where the called function \u201capi call\u201d resides invoke Lam = boto3.client(\u201clambda\u201d,region_name=\u201dus-east-1\u2033) #Define a payload that needs to be passed with a message payload = {\u201cmessage\u201d: \u201cHi, You have been invoked\u201d} #Call the lambda function \u201capical\u201d by using the invoke method of the invokeLam object resp = invoke Lam.invoke(Function Name=\u201dapical\u201d, Invocation Type=\u201dEvent\u201d, Payload=json.dumps(payload)) #resp = invoke Lam.invoke(Function Name=\u201dapical\u201d, Invocation Type=\u201dRequest Response\u201d, Payload=json.dumps(payload)) print(resp) return \u201chello from lambda\u201d[\/source code]<\/p>\n<p><em><i>In <\/i><\/em><strong><em><b><i>\u201capicall\u201d<\/i><\/b><\/em><\/strong><em><i>\u00a0function, the event will contain the payload of the lambda function <\/i><\/em><strong><em><b><i>\u201ccall_lambda_lambda\u201d.<\/i><\/b><\/em><\/strong><\/p>\n<p><strong><b>Step 3: Test your Lambda Function<\/b><\/strong><\/p>\n<p>Once, you have, written the code for your lambda function, click on <strong><b>Save<\/b><\/strong>\u00a0button to save the code.<\/p>\n<p>You can now test your lambda function by clicking on <strong><b>the Test<\/b><\/strong>\u00a0button.<\/p>\n<p>This will prompt you to configure your test event. Enter a name for the test event and click on <strong><b>Create<\/b><\/strong><strong><b><br \/>\n<\/b><\/strong>to<strong><b>\u00a0<\/b><\/strong>create a new test event.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2138\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0171-1024x498-800x389.png\" alt=\"\" width=\"800\" height=\"389\" \/><\/p>\n<p>If your lambda function executes successfully without any errors, it will indicate the success message as shown below.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2139\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0191-1024x459-800x359.png\" alt=\"\" width=\"800\" height=\"359\" \/><\/p>\n<p>You can check the invidual log of <strong><b>call_lambda_lambda<\/b><\/strong>\u00a0function to check if it was successfully executed. You can also check the individual log of <strong><b>apicall <\/b><\/strong>to check if it was successfully invoked by <strong><b>call_lambda_lambda<\/b><\/strong>.<\/p>\n<p><strong><b>Log : call_lambda_lambda<\/b><\/strong><\/p>\n<p><strong><b>\u00a0<\/b><\/strong><a href=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0211.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-1913\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0211-1024x498.png\" alt=\"image021\" width=\"669\" height=\"325\" \/><\/a><\/p>\n<p><strong><b>Log : api call<\/b><\/strong><strong><b><br \/>\n<\/b><\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2140\" src=\"http:\/\/www.aqbsolutions.com\/wp-content\/uploads\/2018\/09\/image0231-1024x498-800x389.png\" alt=\"\" width=\"800\" height=\"389\" \/><\/p>\n<p><strong><b><br \/>\n<\/b><\/strong>Hope, by now, you know how and why one lambda function is invoked by another lambda function.<\/p>\n<p>Keep watching this space for more articles on AWS services.<\/p>\n<p><strong><b>Reference url\u2019s:<\/b><\/strong><\/p>\n<p><strong><b>\u00a0<\/b><\/strong><\/p>\n<p><a href=\"https:\/\/lorenstewart.me\/2017\/10\/02\/serverless-framework-lambdas-invoking-lambdas\/\">https:\/\/lorenstewart.me\/2017\/10\/02\/serverless-framework-lambdas-invoking-lambdas\/<\/a><\/p>\n<p><a href=\"https:\/\/www.oreilly.com\/learning\/how-do-i-invoke-a-lambda-from-another-lambda-in-aws\">https:\/\/www.oreilly.com\/learning\/how-do-i-invoke-a-lambda-from-another-lambda-in-aws<\/a><\/p>\n<p><a href=\"https:\/\/www.youtube.com\/watch?v=5QwrseYLwNM&amp;t=33s\">https:\/\/www.youtube.com\/watch?v=5QwrseYLwNM&amp;t=33s<\/a><\/p>\n<p><a href=\"https:\/\/www.youtube.com\/watch?v=5QwrseYLwNM\">https:\/\/www.youtube.com\/watch?v=5QwrseYLwNM<\/a><\/p>\n<p><a href=\"https:\/\/docs.aws.amazon.com\/lambda\/latest\/dg\/API_Invoke.html\">https:\/\/docs.aws.amazon.com\/lambda\/latest\/dg\/API_Invoke.html<\/a><\/p>\n<p><a href=\"https:\/\/serverfault.com\/questions\/703994\/awslambdaexecute-policy-definition\">https:\/\/serverfault.com\/questions\/703994\/awslambdaexecute-policy-definition<\/a><\/p>\n<p><a href=\"https:\/\/www.youtube.com\/watch?v=sb14OvPrtOk\">https:\/\/www.youtube.com\/watch?v=sb14OvPrtOk<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In the past series of articles on AWS Lambda, you have seen the following : How to set up Lambda on Amazon [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":6118,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"video","meta":{"footnotes":""},"categories":[9],"tags":[2,3,4,5,6,7,10],"class_list":["post-1897","post","type-post","status-publish","format-video","has-post-thumbnail","hentry","category-web-services","tag-amazon","tag-android-2","tag-app","tag-app-development","tag-aws","tag-technology","tag-web-services-2","post_format-post-format-video"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.9 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Invoke an AWS Lamda from Another | aQb Solutions<\/title>\n<meta name=\"description\" content=\"Explore how a lamda function can be called from another lamda function on AWS. There are several ways by which it can be achieved.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Invoke an AWS Lamda from Another | aQb Solutions\" \/>\n<meta property=\"og:description\" content=\"Explore how a lamda function can be called from another lamda function on AWS. There are several ways by which it can be achieved.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog\" \/>\n<meta property=\"article:published_time\" content=\"2018-09-17T16:24:04+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-04-18T06:09:39+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"780\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"aQbSolutions\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"aQbSolutions\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/\"},\"author\":{\"name\":\"aQbSolutions\",\"@id\":\"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/7f8c6dcba99e9b5a7c24a525f8365952\"},\"headline\":\"Invoke a Lambda from another Lambda\",\"datePublished\":\"2018-09-17T16:24:04+00:00\",\"dateModified\":\"2025-04-18T06:09:39+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/\"},\"wordCount\":1227,\"image\":{\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png\",\"keywords\":[\"Amazon\",\"android\",\"app\",\"App Development\",\"aws\",\"technology\",\"Web services\"],\"articleSection\":[\"Web Services\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/\",\"url\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/\",\"name\":\"Invoke an AWS Lamda from Another | aQb Solutions\",\"isPartOf\":{\"@id\":\"https:\/\/aqbsolutions.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png\",\"datePublished\":\"2018-09-17T16:24:04+00:00\",\"dateModified\":\"2025-04-18T06:09:39+00:00\",\"author\":{\"@id\":\"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/7f8c6dcba99e9b5a7c24a525f8365952\"},\"description\":\"Explore how a lamda function can be called from another lamda function on AWS. There are several ways by which it can be achieved.\",\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage\",\"url\":\"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png\",\"contentUrl\":\"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png\",\"width\":1200,\"height\":780,\"caption\":\"Step-by-step guide Replace one Lambda with another\"},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/aqbsolutions.com\/blog\/#website\",\"url\":\"https:\/\/aqbsolutions.com\/blog\/\",\"name\":\"Aqbsolutions Blog\",\"description\":\"Blogs | IT Services in USA and Canada | aQb Solutions\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/aqbsolutions.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/7f8c6dcba99e9b5a7c24a525f8365952\",\"name\":\"aQbSolutions\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/d37e12c5e93bdf3f02abdb5c8a89bad8841bd4743b3b2ea558914abbb60c7414?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/d37e12c5e93bdf3f02abdb5c8a89bad8841bd4743b3b2ea558914abbb60c7414?s=96&d=mm&r=g\",\"caption\":\"aQbSolutions\"},\"url\":\"https:\/\/aqbsolutions.com\/blog\/author\/aqbsolutions\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Invoke an AWS Lamda from Another | aQb Solutions","description":"Explore how a lamda function can be called from another lamda function on AWS. There are several ways by which it can be achieved.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/","og_locale":"en_US","og_type":"article","og_title":"Invoke an AWS Lamda from Another | aQb Solutions","og_description":"Explore how a lamda function can be called from another lamda function on AWS. There are several ways by which it can be achieved.","og_url":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/","og_site_name":"Blog","article_published_time":"2018-09-17T16:24:04+00:00","article_modified_time":"2025-04-18T06:09:39+00:00","og_image":[{"width":1200,"height":780,"url":"http:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png","type":"image\/png"}],"author":"aQbSolutions","twitter_card":"summary_large_image","twitter_misc":{"Written by":"aQbSolutions","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#article","isPartOf":{"@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/"},"author":{"name":"aQbSolutions","@id":"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/7f8c6dcba99e9b5a7c24a525f8365952"},"headline":"Invoke a Lambda from another Lambda","datePublished":"2018-09-17T16:24:04+00:00","dateModified":"2025-04-18T06:09:39+00:00","mainEntityOfPage":{"@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/"},"wordCount":1227,"image":{"@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage"},"thumbnailUrl":"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png","keywords":["Amazon","android","app","App Development","aws","technology","Web services"],"articleSection":["Web Services"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/","url":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/","name":"Invoke an AWS Lamda from Another | aQb Solutions","isPartOf":{"@id":"https:\/\/aqbsolutions.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage"},"image":{"@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage"},"thumbnailUrl":"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png","datePublished":"2018-09-17T16:24:04+00:00","dateModified":"2025-04-18T06:09:39+00:00","author":{"@id":"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/7f8c6dcba99e9b5a7c24a525f8365952"},"description":"Explore how a lamda function can be called from another lamda function on AWS. There are several ways by which it can be achieved.","inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/aqbsolutions.com\/blog\/2018\/09\/17\/invoke-a-lambda-from-another-lambda\/#primaryimage","url":"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png","contentUrl":"https:\/\/aqbsolutions.com\/blog\/wp-content\/uploads\/2018\/09\/Step-by-step-guide-Replace-one-Lambda-with-another.png","width":1200,"height":780,"caption":"Step-by-step guide Replace one Lambda with another"},{"@type":"WebSite","@id":"https:\/\/aqbsolutions.com\/blog\/#website","url":"https:\/\/aqbsolutions.com\/blog\/","name":"Aqbsolutions Blog","description":"Blogs | IT Services in USA and Canada | aQb Solutions","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/aqbsolutions.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/7f8c6dcba99e9b5a7c24a525f8365952","name":"aQbSolutions","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/aqbsolutions.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/d37e12c5e93bdf3f02abdb5c8a89bad8841bd4743b3b2ea558914abbb60c7414?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/d37e12c5e93bdf3f02abdb5c8a89bad8841bd4743b3b2ea558914abbb60c7414?s=96&d=mm&r=g","caption":"aQbSolutions"},"url":"https:\/\/aqbsolutions.com\/blog\/author\/aqbsolutions\/"}]}},"_links":{"self":[{"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1897","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=1897"}],"version-history":[{"count":3,"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1897\/revisions"}],"predecessor-version":[{"id":6121,"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1897\/revisions\/6121"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/media\/6118"}],"wp:attachment":[{"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=1897"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=1897"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/aqbsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=1897"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}