{"id":8063,"date":"2024-03-08T15:20:33","date_gmt":"2024-03-08T08:20:33","guid":{"rendered":"https:\/\/www.briswell-vn.com\/?p=8063"},"modified":"2024-04-01T08:51:54","modified_gmt":"2024-04-01T01:51:54","slug":"debugging-aws-lambda-voi-localstack","status":"publish","type":"post","link":"https:\/\/www.briswell-vn.com\/en\/news\/debugging-aws-lambda-voi-localstack\/","title":{"rendered":"Debugging AWS Lambda with LocalStack"},"content":{"rendered":"<p><\/p>\n<h2>What is LocalStack?<\/h2>\n<p>LocalStack is an open-source software development tool that helps you deploy and run applications in a simulated cloud environment on your personal computer or server. It provides a replica of many popular cloud services, such as Amazon S3, AWS Lambda, DynamoDB, and many others. This allows you to develop, test, and debug your applications without having to connect to a real cloud environment.<\/p>\n<h2>Installation<\/h2>\n<h3>Install LocalStack<\/h3>\n<p>Follow the instructions at the following link to install LocalStack:<\/p>\n<p><a href=\"https:\/\/docs.localstack.cloud\/getting-started\/installation\/\">https:\/\/docs.localstack.cloud\/getting-started\/installation\/<\/a><\/p>\n<h3>Install Docker<\/h3>\n<p>Follow the instructions at the following link to install Docker:<\/p>\n<p><a href=\"https:\/\/docs.docker.com\/engine\/install\/\">https:\/\/docs.docker.com\/engine\/install\/<\/a><\/p>\n<h3>Install AWS CLI<\/h3>\n<p>Follow the instructions at the following link to install AWS CLI and configure a profile for the local environment:<\/p>\n<p><a href=\"https:\/\/docs.localstack.cloud\/user-guide\/integrations\/aws-cli\/#aws-cli\">https:\/\/docs.localstack.cloud\/user-guide\/integrations\/aws-cli\/#aws-cli<\/a><\/p>\n<h2>Setup LocalStack<\/h2>\n<h3>Create docker-compose.yml file<\/h3>\n<p>We will start LocalStack with a Docker-Compose setup. Create a new file named docker-compose.yml and add the following configuration:<\/p>\n<div>\n<pre>version: \"3.8\"\r\n\r\nservices:\r\n  localstack:\r\n  \u00a0 container_name: \"${LOCALSTACK_DOCKER_NAME-localstack_main}\"  # Name of the container to be used\r\n  \u00a0 image: localstack\/localstack:latest  # Docker image for LocalStack, latest version\r\n  \u00a0 ports:\r\n  \u00a0 \u00a0 - \"127.0.0.1:4566:4566\" \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0# Port for accessing LocalStack Gateway from the local machine\r\n  \u00a0 \u00a0 - \"127.0.0.1:4510-4559:4510-4559\"  # Port range for external services\r\n  \u00a0 environment:\r\n  \u00a0 \u00a0 - DEBUG=1  # Enable Debug mode in LocalStack\r\n  \u00a0 \u00a0 - LAMBDA_REMOTE_DOCKER=0  # Turn off remote Docker usage for Lambda\r\n  \u00a0 \u00a0 - LAMBDA_DOCKER_FLAGS=-e NODE_OPTIONS=--inspect-brk=0.0.0.0:9229 -p 9229:9229  # Exposes port 9229 for debugging the Lambda handler code.\r\n  \u00a0 \u00a0 - LAMBDA_EXECUTOR=${LAMBDA_EXECUTOR-}  <span class=\"hljs-comment\"># Lambda execution type (if defined)<\/span>\r\n  \u00a0 \u00a0 - DOCKER_HOST=unix:\/\/\/var\/run\/docker.sock  # Link to Docker via Docker socket\r\n  \u00a0 volumes:\r\n  \u00a0 \u00a0 - \"${LOCALSTACK_VOLUME_DIR:-.\/volume}:\/var\/lib\/localstack\"  # Mount point for LocalStack data directory\r\n  \u00a0 \u00a0 - \"\/var\/run\/docker.sock:\/var\/run\/docker.sock\"  <span class=\"hljs-comment\"># Mount Docker socket to access Docker from the LocalStack container<\/span><\/pre>\n<\/div>\n<div>In addition, to see other configurations of LocalStack, you can refer to the following link:<\/div>\n<div><a href=\"https:\/\/docs.localstack.cloud\/references\/configuration\/\">https:\/\/docs.localstack.cloud\/references\/configuration\/<\/a><\/div>\n<h3>Start up LocalStack with Docker<\/h3>\n<p>We will run the following command to start LocalStack:<\/p>\n<pre>docker-compose up -d<\/pre>\n<p>After running the above command, we see that the Docker Container is running<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8068 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12132634\/docker-container-start.png\" alt=\"\" width=\"1903\" height=\"832\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12132634\/docker-container-start.png 1903w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12132634\/docker-container-start-300x131.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12132634\/docker-container-start-1024x448.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12132634\/docker-container-start-768x336.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12132634\/docker-container-start-1536x672.png 1536w\" sizes=\"auto, (max-width: 1903px) 100vw, 1903px\" \/><\/p>\n<p>And successfully started LocalStack<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8069 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12134424\/localstack-start-success.png\" alt=\"\" width=\"1882\" height=\"902\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12134424\/localstack-start-success.png 1882w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12134424\/localstack-start-success-300x144.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12134424\/localstack-start-success-1024x491.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12134424\/localstack-start-success-768x368.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/12134424\/localstack-start-success-1536x736.png 1536w\" sizes=\"auto, (max-width: 1882px) 100vw, 1882px\" \/><\/p>\n<h2><\/h2>\n<h2 id=\"heading-setting-up-remote-debugging\" class=\"permalink-heading\">Setup Lambda Function Debugging<\/h2>\n<h3>Create launch.json file<\/h3>\n<p>We create a .vscode\/launch.json file and add the following configuration:<\/p>\n<div>\n<pre>{\r\n  \"version\": \"0.2.0\",\r\n  \"configurations\": [\r\n  \u00a0 {\r\n  \u00a0 \u00a0 \"address\": \"127.0.0.1\",\r\n  \u00a0 \u00a0 \"localRoot\": \"${workspaceFolder}\",\r\n  \u00a0 \u00a0 \"name\": \"Attach to Remote Node.js\",\r\n  \u00a0 \u00a0 \"port\": 9229,\r\n  \u00a0 \u00a0 \"remoteRoot\": \"\/var\/task\/\",\r\n  \u00a0 \u00a0 \"request\": \"attach\",\r\n  \u00a0 \u00a0 \"type\": \"node\",\r\n  \u00a0 \u00a0 \"preLaunchTask\": \"Wait Remote Debugger Server\"\r\n  \u00a0 },\r\n  ]\r\n}<\/pre>\n<\/div>\n<h3>Create tasks.json file<\/h3>\n<p>We create a .vscode\/tasks.json file and add the following configuration:<\/p>\n<pre>{\r\n  \"version\": \"2.0.0\",\r\n  \"tasks\": [\r\n    {\r\n      \"label\": \"Wait Remote Debugger Server\",\r\n      \"type\": \"shell\",\r\n      \"command\": \"while [[ -z $(docker ps | grep :9229) ]]; do sleep 1; done; sleep 1;\"\r\n    }\r\n  ]\r\n}<\/pre>\n<p>Note: The above code only executes on Linux and macOS. If you are using Windows, do the following:<\/p>\n<p>Create a .vscode\/tasks.json file<\/p>\n<div>\n<pre>{\r\n  \"version\": \"2.0.0\",\r\n  \"tasks\": [\r\n  \u00a0 {\r\n  \u00a0 \u00a0 \"label\": \"Wait Remote Debugger Server\",\r\n  \u00a0 \u00a0 \"type\": \"shell\",\r\n  \u00a0 \u00a0 \"command\": \"powershell\",\r\n  \u00a0 \u00a0 \"args\": [\r\n  \u00a0 \u00a0 \u00a0 \".\\\\.vscode\\\\wait-debugger.ps1\"\r\n  \u00a0 \u00a0 ]\r\n  \u00a0 }\r\n  ]\r\n}<\/pre>\n<\/div>\n<div><\/div>\n<div>Create a .vscode\/wait-debugger.ps1 file<\/div>\n<div>\n<pre>while (-not (docker ps | Select-String \":9229\")) {\r\n  Start-Sleep -Seconds 1\r\n}\r\nStart-Sleep -Seconds 1<\/pre>\n<h3>Create function.ts file<\/h3>\n<p>In this example, we will create a function.ts file containing Lambda Function code using Node.js and TypeScript for debug testing:<\/p>\n<pre>export const \u00a0handler = async (event: any) =&gt; \u00a0{\r\n  const response = {\r\n    statusCode: 200,\r\n    body: \"hello word\",\r\n  };\r\n  return response;\r\n};<\/pre>\n<h2>Create Lambda Function on LocalStack<\/h2>\n<p>To create a Lambda Function on LocalStack we use the following command:<\/p>\n<pre>aws --endpoint-url=http:\/\/localhost:4566 lambda create-function \\\r\n--function-name localstack-lambda-function \\\r\n--code S3Bucket=\"hot-reload\",S3Key=\"$(pwd)\/\" \\\r\n--handler function.handler \\\r\n--runtime nodejs18.x \\\r\n--timeout 120 \\\r\n--role arn:aws:iam::000000000000:role\/lambda-role<\/pre>\n<p>After running the above command, the Lambda Function has been successfully created on LocalStack<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8071 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13084745\/create-lambda-function-on-localstack.png\" alt=\"\" width=\"1887\" height=\"912\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13084745\/create-lambda-function-on-localstack.png 1887w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13084745\/create-lambda-function-on-localstack-300x145.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13084745\/create-lambda-function-on-localstack-1024x495.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13084745\/create-lambda-function-on-localstack-768x371.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13084745\/create-lambda-function-on-localstack-1536x742.png 1536w\" sizes=\"auto, (max-width: 1887px) 100vw, 1887px\" \/><\/p>\n<h2><\/h2>\n<h2>Implement Debugging Lambda Function<\/h2>\n<p>In VS Code you can debug by placing breakpoints where the code needs to be debugged and pressing F5 to run<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8072 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091141\/start-debug-lambda-local.png\" alt=\"\" width=\"1915\" height=\"995\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091141\/start-debug-lambda-local.png 1915w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091141\/start-debug-lambda-local-300x156.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091141\/start-debug-lambda-local-1024x532.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091141\/start-debug-lambda-local-768x399.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091141\/start-debug-lambda-local-1536x798.png 1536w\" sizes=\"auto, (max-width: 1915px) 100vw, 1915px\" \/><\/p>\n<p>Then execute the Lambda Function with the following command:<\/p>\n<pre>aws --endpoint-url=http:\/\/localhost:4566 lambda invoke \\\r\n--function-name localstack-lambda-function lambda.log \\\r\n--cli-binary-format raw-in-base64-out \\\r\n--payload '{\"hello\":\"world\"}'<\/pre>\n<\/div>\n<p>After running the above command, you have successfully debugged<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8073 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091644\/debug-success.png\" alt=\"\" width=\"1920\" height=\"986\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091644\/debug-success.png 1920w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091644\/debug-success-300x154.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091644\/debug-success-1024x526.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091644\/debug-success-768x394.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2023\/10\/13091644\/debug-success-1536x789.png 1536w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/p>\n<h2>Implement Debugging Lambda Function with Amazon S3 to trigger AWS Lambda when uploading files<\/h2>\n<h3>Create a bucket on Amazon S3<\/h3>\n<p>To create a bucket on Amazon S3, we use the following command:<\/p>\n<pre>aws s3api create-bucket --bucket local-stack-bucket --create-bucket-configuration LocationConstraint=ap-northeast-1 --endpoint-url=http:\/\/localhost:4566<\/pre>\n<p>In there:<\/p>\n<p>+ <strong>local-stack-bucket:<\/strong>\u00a0 is the name of the bucket<\/p>\n<h3>Configure Amazon S3 trigger to Lambda Function<\/h3>\n<p>To trigger the Lambda Function when uploading a file to Amazon S3, we use the following command:<\/p>\n<pre>aws --endpoint-url=http:\/\/localhost:4566 s3api put-bucket-notification-configuration \\\r\n    --bucket local-stack-bucket \\\r\n    --notification-configuration '{\r\n        \"LambdaFunctionConfigurations\": [\r\n          {\r\n            \"Id\": \"1\", \r\n            \"LambdaFunctionArn\": \"arn:aws:lambda:ap-northeast-1:000000000000:function:localstack-lambda-function\",\r\n            \"Events\": [\"s3:ObjectCreated:*\"]\r\n          }\r\n        ]\r\n    }'<\/pre>\n<p>In there:<\/p>\n<p>+ <strong>local-stack-bucket:<\/strong>\u00a0 is the name of the bucket to be configured<\/p>\n<p>+ <strong>LambdaFunctionArn:<\/strong>\u00a0 is the Arn of the Lambda Function that needs to trigger<\/p>\n<p>+ <strong>Events: <\/strong>is an event on Amazon S3 that triggers a Lambda Function<\/p>\n<h3>Proceed to debug the Lambda Function<\/h3>\n<p>In VS Code you can debug by placing breakpoints where the code needs to be debugged and pressing F5 to run<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8174 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05135231\/code-debug-1.png\" alt=\"\" width=\"1917\" height=\"973\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05135231\/code-debug-1.png 1917w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05135231\/code-debug-1-300x152.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05135231\/code-debug-1-1024x520.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05135231\/code-debug-1-768x390.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05135231\/code-debug-1-1536x780.png 1536w\" sizes=\"auto, (max-width: 1917px) 100vw, 1917px\" \/><\/p>\n<p>Then proceed to upload the file to the Amazon S3 bucket on the LocalStack cloud<\/p>\n<h3><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8176 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145618\/app-localstack.png\" alt=\"\" width=\"1881\" height=\"677\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145618\/app-localstack.png 1881w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145618\/app-localstack-300x108.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145618\/app-localstack-1024x369.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145618\/app-localstack-768x276.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145618\/app-localstack-1536x553.png 1536w\" sizes=\"auto, (max-width: 1881px) 100vw, 1881px\" \/><\/h3>\n<p>&nbsp;<\/p>\n<p>After uploading the file, you have successfully debugged<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-8177 size-full\" src=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145927\/result-debug.png\" alt=\"\" width=\"1912\" height=\"975\" srcset=\"https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145927\/result-debug.png 1912w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145927\/result-debug-300x153.png 300w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145927\/result-debug-1024x522.png 1024w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145927\/result-debug-768x392.png 768w, https:\/\/s3-ap-southeast-1.amazonaws.com\/homepage-media\/wp-content\/uploads\/2024\/02\/05145927\/result-debug-1536x783.png 1536w\" sizes=\"auto, (max-width: 1912px) 100vw, 1912px\" \/><\/p>\n<h2>The Drawbacks of LocalStack<\/h2>\n<p><strong>Limited Support For AWS Services:<\/strong>\u00a0 LocalStack provides emulation for several important services such as S3, DynamoDB, Lambda, and SQS. However, not all AWS services are supported, and some services may be unavailable or implemented with only some basic features. This can be a hassle if your application depends on unsupported services.<\/p>\n<p><strong>Missing Features: <\/strong>Although LocalStack helps simulate services, not all of their features are implemented. Configuration options can be limited, reducing compatibility between the local development environment and the actual environment on AWS.<\/p>\n<p><strong>Limited Scalability: <\/strong>LocalStack is not designed to scale as aggressively as the AWS environment. If you are working on large projects at scale, testing and development in a local environment may not reflect reality on AWS.<\/p>\n<p><strong>Delay: <\/strong>Due to emulation and attempts to replicate AWS services, LocalStack may experience delays compared to the actual use of services. This can reduce performance and slow down development and testing.<\/p>\n<p><strong>Slow Update: <\/strong>LocalStack may not update quickly with new versions of AWS services. This can lead to asynchrony when new features are needed or when there are changes in the AWS API.<\/p>\n<h2>Conclusion<\/h2>\n<p>Using LocalStack helps us develop and debug Lambda Functions, as well as other AWS services, effectively in a local environment. It helps ensure proper integration and functionality before deploying to actual AWS, saving time, and cost, and reducing impact on your real AWS account during development.<\/p>\n<h2>References<\/h2>\n<p><a href=\"https:\/\/docs.localstack.cloud\/\">https:\/\/docs.localstack.cloud\/<\/a><\/p>","protected":false},"excerpt":{"rendered":"<p>What is LocalStack? LocalStack is an open-source software development tool that helps you deploy and run applications in a simulated cloud environment on your personal computer or server. It provides a replica of many popular cloud services, such as Amazon S3, AWS Lambda, DynamoDB, and many others. This allows you to develop, test, and debug your applications without having to connect to a real cloud [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":8064,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_mi_skip_tracking":false,"footnotes":""},"categories":[4,71],"tags":[],"class_list":["post-8063","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-news","category-it-tec"],"_links":{"self":[{"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/posts\/8063","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/comments?post=8063"}],"version-history":[{"count":0,"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/posts\/8063\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/media\/8064"}],"wp:attachment":[{"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/media?parent=8063"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/categories?post=8063"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.briswell-vn.com\/en\/wp-json\/wp\/v2\/tags?post=8063"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}