0Pricing
Serverless AWS Lambda Development · Lekcja

Pierwsza funkcja Lambda

Napisz, skonfiguruj i wdroż prostą funkcję Lambda „Hello World” za pomocą konsoli AWS, zdobywając praktyczne doświadczenie z platformą.

Pierwsza funkcja Lambda to bezpłatna lekcja Serverless AWS Lambda Development na CoddyKit. To lekcja 3 z 4. Możesz przeczytać całą lekcję poniżej za darmo — a potem ćwiczyć ją interaktywnie w przeglądarce z wbudowanym edytorem kodu i tutorem AI dostępnym 24/7. To część ścieżki edukacyjnej Serverless AWS Lambda Development, a Twój postęp synchronizuje się między webem a aplikacją CoddyKit. Kurs Serverless AWS Lambda Development zawiera 4 lekcji w sumie.

Części tej lekcji nie zostały jeszcze przetłumaczone i są wyświetlane po angielsku.

Your First Lambda Function

Time to build! You will create and deploy your first Hello World Lambda right in the AWS console — your practical step into serverless.

Find Lambda in AWS Console

Log into the AWS console, search "Lambda" in the top bar, and select it to open the Lambda dashboard where all your functions live.

Start a New Lambda Function

On the dashboard, click Create function and choose "Author from scratch" to define a brand-new serverless function.

Name Your Function & Runtime

Set the basics: a unique Function name and a Runtime — the language your code runs in. We will use Python 3.9 here.

Lambda's Permissions: Execution Role

Your function needs an execution role (an IAM role) for permissions. Pick "Create a new role with basic Lambda permissions" to allow CloudWatch logs.

Code Your 'Hello World'

The console opens a code editor — replace the default with this simple Python Hello World handler.

import json

def lambda_handler(event, context):
    # Log the event for debugging purposes
    print(f"Received event: {event}")

    # Return a simple greeting
    return {
        'statusCode': 200,
        'body': json.dumps('Hello from your first Lambda!')
    }

Save & Deploy Your Function

After editing, click Deploy to save your changes and make the new version live. Skip this and the Lambda service keeps the old code.

Test Your Lambda Function

Open the Test tab and configure a test event — the hello-world template works — name it, then click Test to invoke your function and see results.

Check Logs for Output

After a test, results appear inline. For full output, including your print() statements, open CloudWatch Logs where Lambda sends its runtime logs.

Quick Check: Lambda Deployment

You've just deployed your first Lambda! Let's check your understanding of the essential steps.

Recap: Your First Lambda

Congrats! You created, configured, coded, deployed, and tested your first Lambda function — the foundational skill for serverless apps.

Często zadawane pytania

Czy lekcja „Pierwsza funkcja Lambda” jest bezpłatna?

Tak — pełny tekst „Pierwsza funkcja Lambda” jest dostępny za darmo tutaj w sieci. Aby ćwiczyć ją interaktywnie (wbudowany edytor kodu i tutor AI dostępny 24/7) i odblokować resztę kursu Serverless AWS Lambda Development, przejdź na CoddyKit PRO. Kurs Serverless AWS Lambda Development zawiera 4 lekcji w sumie.

Co nauczysz się w „Pierwsza funkcja Lambda”?

Napisz, skonfiguruj i wdroż prostą funkcję Lambda „Hello World” za pomocą konsoli AWS, zdobywając praktyczne doświadczenie z platformą. Ćwiczysz Serverless AWS Lambda Development z praktycznym kodem, który uruchamiasz bezpośrednio w przeglądarce, a tutor AI dostępny 24/7 odpowiada na Twoje pytania podczas pracy nad lekcją.

Czy potrzebuję doświadczenia, aby zacząć Serverless AWS Lambda Development?

Nie wymagamy żadnego doświadczenia. Serverless AWS Lambda Development w CoddyKit jest strukturyzowany dla początkujących i zaawansowanych użytkowników, więc możesz zacząć tutaj lub od początku i uczyć się w swoim tempie. To lekcja 3 z 4.

Ile czasu zajmuje lekcja „Pierwsza funkcja Lambda”?

Większość lekcji CoddyKit trwa około 5–10 minut. Każda lekcja to mały, interaktywny krok, dzięki czemu robisz systematyczne postępy i zawsze wracasz dokładnie do tego samego miejsca — na webie i w aplikacji.

Czy mogę pisać i uruchamiać kod w tej lekcji Serverless AWS Lambda Development?

Tak. Każda lekcja Serverless AWS Lambda Development zawiera wbudowany edytor kodu, więc piszesz i uruchamiasz prawdziwy kod bezpośrednio w przeglądarce i od razu otrzymujesz sprzężenie zwrotne od AI — bez konfiguracji na komputerze.

Wszystkie lekcje w tym kursie

  1. Czym jest serverless computing?
  2. Pierwsze kroki z AWS Lambda
  3. Pierwsza funkcja Lambda
  4. Ceny serverless i bezpłatny poziom
← Powrót do Serverless AWS Lambda Development