{"id":39027,"date":"2026-02-12T19:40:56","date_gmt":"2026-02-12T16:40:56","guid":{"rendered":"https:\/\/fatihsoysal.com\/blog\/?p=39027"},"modified":"2026-02-12T19:40:56","modified_gmt":"2026-02-12T16:40:56","slug":"spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber","status":"publish","type":"post","link":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/","title":{"rendered":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber"},"content":{"rendered":"<p><body><\/p>\n<h2>Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber<\/h2>\n<h3>Giri\u015f: RESTful Web Servisleri ve Spring \u00c7er\u00e7evesi<\/h3>\n<p>Modern yaz\u0131l\u0131m d\u00fcnyas\u0131nda, farkl\u0131 sistemlerin birbiriyle ileti\u015fim kurmas\u0131 temel bir ihtiya\u00e7t\u0131r. Bu ileti\u015fimi sa\u011flaman\u0131n en pop\u00fcler yollar\u0131ndan biri, Representational State Transfer (REST) mimari stilini kullanan web servisleridir. RESTful web servisleri, genellikle HTTP protokol\u00fc \u00fczerinden \u00e7al\u0131\u015f\u0131r ve kaynaklar\u0131 (resources) temsil eden URL&#8217;ler arac\u0131l\u0131\u011f\u0131yla eri\u015filir. Bu servisler, durumsuz (stateless) olmalar\u0131, istemci-sunucu ayr\u0131m\u0131, \u00f6nbelleklenebilirlik ve katmanl\u0131 sistem gibi prensiplere dayan\u0131r. Bu prensipler, servislerin \u00f6l\u00e7eklenebilir, g\u00fcvenilir ve bak\u0131m\u0131 kolay olmas\u0131n\u0131 sa\u011flar.<\/p>\n<p>Spring Framework, \u00f6zellikle Spring Boot ile birlikte, RESTful web servisleri geli\u015ftirmek i\u00e7in en g\u00fc\u00e7l\u00fc ve yayg\u0131n olarak kullan\u0131lan platformlardan biridir. Spring&#8217;in sa\u011flad\u0131\u011f\u0131 <code>@RestController<\/code>, <code>@RequestMapping<\/code> gibi anotasyonlar ve otomatik yap\u0131land\u0131rma yetenekleri sayesinde, geli\u015ftiriciler h\u0131zl\u0131 ve etkin bir \u015fekilde REST API&#8217;leri olu\u015fturabilirler. Spring Boot&#8217;un &#8220;convention over configuration&#8221; yakla\u015f\u0131m\u0131, boilerplate kodunu azaltarak geli\u015ftirme s\u00fcrecini \u00f6nemli \u00f6l\u00e7\u00fcde h\u0131zland\u0131r\u0131r. Bu makalede, Spring Boot kullanarak hem JSON (JavaScript Object Notation) hem de XML (Extensible Markup Language) formatlar\u0131nda veri \u00fcreten ve t\u00fcketen RESTful servislerin nas\u0131l geli\u015ftirilece\u011fini ayr\u0131nt\u0131l\u0131 bir \u015fekilde inceleyece\u011fiz.<\/p>\n<h3>Veri Formatlar\u0131: JSON ve XML<\/h3>\n<p>RESTful servisler, kaynaklar\u0131n temsilini istemciye veya sunucuya iletmek i\u00e7in belirli veri formatlar\u0131n\u0131 kullan\u0131r. En yayg\u0131n kullan\u0131lan iki format JSON ve XML&#8217;dir. Her iki format\u0131n da kendine \u00f6zg\u00fc avantajlar\u0131 ve dezavantajlar\u0131 vard\u0131r ve kullan\u0131m senaryolar\u0131na g\u00f6re tercih edilebilirler.<\/p>\n<h4>JSON (JavaScript Object Notation)<\/h4>\n<p>JSON, hafif, insan taraf\u0131ndan okunabilir ve kolayca ayr\u0131\u015ft\u0131r\u0131labilir bir veri de\u011fi\u015fim format\u0131d\u0131r. JavaScript nesne s\u00f6zdizimine dayan\u0131r ancak dilden ba\u011f\u0131ms\u0131zd\u0131r. Anahtar-de\u011fer \u00e7iftleri ve dizi yap\u0131lar\u0131 ile verileri temsil eder.<\/p>\n<p><strong>JSON \u00d6rne\u011fi:<\/strong><\/p>\n<pre><code class=\"language-json\">{\n  \"id\": 1,\n  \"name\": \"Laptop\",\n  \"price\": 1200.00,\n  \"available\": true,\n  \"tags\": [\"electronics\", \"computer\"]\n}<\/code><\/pre>\n<p><strong>JSON Avantajlar\u0131:<\/strong><br \/>\n*   <strong>Hafif ve Kompakt:<\/strong> XML&#8217;e g\u00f6re genellikle daha az karakterle ayn\u0131 veriyi temsil eder, bu da a\u011f trafi\u011fini azalt\u0131r.<br \/>\n*   <strong>Kolay Okunabilirlik:<\/strong> Yap\u0131s\u0131 basittir ve insanlar taraf\u0131ndan kolayca anla\u015f\u0131labilir.<br \/>\n*   <strong>H\u0131zl\u0131 Ayr\u0131\u015ft\u0131rma:<\/strong> \u00c7o\u011fu programlama dilinde JSON ayr\u0131\u015ft\u0131rma (parsing) k\u00fct\u00fcphaneleri olduk\u00e7a h\u0131zl\u0131 ve etkilidir.<br \/>\n*   <strong>Taray\u0131c\u0131 Deste\u011fi:<\/strong> Web taray\u0131c\u0131lar\u0131 ve JavaScript uygulamalar\u0131yla do\u011fal uyumlulu\u011fu vard\u0131r.<\/p>\n<p><strong>JSON Dezavantajlar\u0131:<\/strong><br \/>\n*   <strong>\u015eema Tan\u0131m\u0131 Eksikli\u011fi:<\/strong> XML&#8217;deki gibi yerle\u015fik bir \u015fema tan\u0131m\u0131 mekanizmas\u0131 yoktur (ancak JSON Schema gibi harici standartlar mevcuttur).<br \/>\n*   <strong>Yorum Deste\u011fi Yok:<\/strong> Veri i\u00e7inde yorum sat\u0131r\u0131 b\u0131rakma \u00f6zelli\u011fi yoktur.<\/p>\n<h4>XML (Extensible Markup Language)<\/h4>\n<p>XML, hem insanlar hem de makineler taraf\u0131ndan okunabilir bir formatta yap\u0131land\u0131r\u0131lm\u0131\u015f verileri kodlamak i\u00e7in kullan\u0131lan bir i\u015faretleme dilidir. Etiketler (tags) kullanarak verileri hiyerar\u015fik bir yap\u0131da d\u00fczenler.<\/p>\n<p><strong>XML \u00d6rne\u011fi:<\/strong><\/p>\n<pre><code class=\"language-xml\"><product>\n  <id>1<\/id>\n  <name>Laptop<\/name>\n  <price>1200.00<\/price>\n  <available>true<\/available>\n  <tags>\n    <tag>electronics<\/tag>\n    <tag>computer<\/tag>\n  <\/tags>\n<\/product><\/code><\/pre>\n<p><strong>XML Avantajlar\u0131:<\/strong><br \/>\n*   <strong>\u015eema Deste\u011fi:<\/strong> DTD (Document Type Definition) veya XML Schema (XSD) gibi standartlarla veri yap\u0131s\u0131 ve i\u00e7eri\u011fi tan\u0131mlanabilir, bu da veri do\u011frulama i\u00e7in g\u00fc\u00e7l\u00fc bir mekanizma sa\u011flar.<br \/>\n*   <strong>Geni\u015fletilebilirlik:<\/strong> Yeni etiketler ve yap\u0131lar ekleyerek mevcut format\u0131 kolayca geni\u015fletilebilir.<br \/>\n*   <strong>Yorum Deste\u011fi:<\/strong> Veri i\u00e7inde yorum sat\u0131rlar\u0131 b\u0131rak\u0131labilir.<br \/>\n*   <strong>Olgun Ekosistem:<\/strong> XML ile \u00e7al\u0131\u015fmak i\u00e7in \u00e7ok say\u0131da ara\u00e7, k\u00fct\u00fcphane ve standart (XPath, XSLT vb.) mevcuttur.<\/p>\n<p><strong>XML Dezavantajlar\u0131:<\/strong><br \/>\n*   <strong>A\u011f\u0131r ve Hacimli:<\/strong> JSON&#8217;a g\u00f6re genellikle daha fazla karakter ve etiket kullan\u0131r, bu da dosya boyutunu ve a\u011f trafi\u011fini art\u0131r\u0131r.<br \/>\n*   <strong>Karma\u015f\u0131k Ayr\u0131\u015ft\u0131rma:<\/strong> Ayr\u0131\u015ft\u0131rma i\u015flemi JSON&#8217;a g\u00f6re daha karma\u015f\u0131k ve yava\u015f olabilir.<br \/>\n*   <strong>Daha Az \u0130nsan Odakl\u0131:<\/strong> Etiket kalabal\u0131\u011f\u0131 nedeniyle JSON&#8217;a g\u00f6re okunabilirli\u011fi biraz daha d\u00fc\u015f\u00fckt\u00fcr.<\/p>\n<h4>Hangi Durumda Hangisi Tercih Edilmeli?<\/h4>\n<p>*   <strong>JSON:<\/strong> Mobil uygulamalar, modern web uygulamalar\u0131 (\u00f6zellikle JavaScript tabanl\u0131 frontend&#8217;ler), mikroservisler aras\u0131 ileti\u015fim ve y\u00fcksek performans gerektiren senaryolar i\u00e7in idealdir. Hafifli\u011fi ve kolay ayr\u0131\u015ft\u0131rma yetene\u011fi, onu bu alanlarda pop\u00fcler k\u0131lar.<br \/>\n*   <strong>XML:<\/strong> Kurumsal uygulamalar, eski sistemlerle entegrasyon, veri do\u011frulaman\u0131n kritik oldu\u011fu veya karma\u015f\u0131k belge yap\u0131lar\u0131n\u0131 temsil etme ihtiyac\u0131 olan durumlar i\u00e7in tercih edilebilir. SOAP gibi eski web servis standartlar\u0131 genellikle XML kullan\u0131r.<\/p>\n<p>Spring Framework, her iki format\u0131 da sorunsuz bir \u015fekilde destekler ve geli\u015ftiricilere i\u00e7erik anla\u015fmas\u0131 (content negotiation) mekanizmalar\u0131 arac\u0131l\u0131\u011f\u0131yla istemcinin tercihine g\u00f6re yan\u0131t verme esnekli\u011fi sunar.<\/p>\n<h3>Spring Boot ile Proje Kurulumu<\/h3>\n<p>Spring Boot, h\u0131zl\u0131 ve kolay bir \u015fekilde Spring uygulamalar\u0131 olu\u015fturmak i\u00e7in tasarlanm\u0131\u015ft\u0131r. Yeni bir Spring Boot projesi olu\u015fturmak i\u00e7in Spring Initializr (start.spring.io) kullan\u0131labilir.<\/p>\n<h4>Gerekli Ba\u011f\u0131ml\u0131l\u0131klar (pom.xml)<\/h4>\n<p>Bir Spring Boot REST API projesi i\u00e7in temel ba\u011f\u0131ml\u0131l\u0131klar \u015funlard\u0131r:<\/p>\n<p>*   <strong><code>spring-boot-starter-web<\/code><\/strong>: Spring MVC&#8217;yi, g\u00f6m\u00fcl\u00fc Tomcat sunucusunu ve RESTful servisler olu\u015fturmak i\u00e7in gerekli di\u011fer ba\u011f\u0131ml\u0131l\u0131klar\u0131 i\u00e7erir.<br \/>\n*   <strong><code>jackson-dataformat-xml<\/code><\/strong>: Spring&#8217;in Jackson k\u00fct\u00fcphanesini kullanarak XML verilerini JSON gibi otomatik olarak serile\u015ftirmesini ve tersine serile\u015ftirmesini (marshalling\/unmarshalling) sa\u011flar. JSON i\u00e7in <code>spring-boot-starter-web<\/code> zaten <code>jackson-databind<\/code>&#8216;i i\u00e7erir.<\/p>\n<p>Projenizin <code>pom.xml<\/code> dosyas\u0131na a\u015fa\u011f\u0131daki ba\u011f\u0131ml\u0131l\u0131klar\u0131 eklemeniz gerekmektedir:<\/p>\n<pre><code class=\"language-xml\"><?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<project xmlns=\"http:\/\/maven.apache.org\/POM\/4.0.0\" xmlns:xsi=\"http:\/\/www.w3.org\/2001\/XMLSchema-instance\"\n         xsi:schemaLocation=\"http:\/\/maven.apache.org\/POM\/4.0.0 https:\/\/maven.apache.org\/xsd\/maven-4.0.0.xsd\">\n    <modelVersion>4.0.0<\/modelVersion>\n    <parent>\n        <groupId>org.springframework.boot<\/groupId>\n        <artifactId>spring-boot-starter-parent<\/artifactId>\n        <version>3.2.5<\/version> <!-- G\u00fcncel bir s\u00fcr\u00fcm kullan\u0131n -->\n        <relativePath\/> <!-- lookup parent from repository -->\n    <\/parent>\n    <groupId>com.example<\/groupId>\n    <artifactId>spring-rest-xml-json<\/artifactId>\n    <version>0.0.1-SNAPSHOT<\/version>\n    <name>spring-rest-xml-json<\/name>\n    <description>Spring REST XML and JSON Example<\/description>\n\n    <properties>\n        <java.version>17<\/java.version>\n    <\/properties>\n\n    <dependencies>\n        <dependency>\n            <groupId>org.springframework.boot<\/groupId>\n            <artifactId>spring-boot-starter-web<\/artifactId>\n        <\/dependency>\n\n        <!-- XML deste\u011fi i\u00e7in Jackson XML mod\u00fcl\u00fcn\u00fc ekleyin -->\n        <dependency>\n            <groupId>com.fasterxml.jackson.dataformat<\/groupId>\n            <artifactId>jackson-dataformat-xml<\/artifactId>\n        <\/dependency>\n\n        <dependency>\n            <groupId>org.springframework.boot<\/groupId>\n            <artifactId>spring-boot-starter-test<\/artifactId>\n            <scope>test<\/scope>\n        <\/dependency>\n    <\/dependencies>\n\n    <build>\n        <plugins>\n            <plugin>\n                <groupId>org.springframework.boot<\/groupId>\n                <artifactId>spring-boot-maven-plugin<\/artifactId>\n            <\/plugin>\n        <\/plugins>\n    <\/build>\n\n<\/project><\/code><\/pre>\n<p><code>jackson-dataformat-xml<\/code> ba\u011f\u0131ml\u0131l\u0131\u011f\u0131, Spring&#8217;in Jackson k\u00fct\u00fcphanesini kullanarak POJO&#8217;lar\u0131 (Plain Old Java Objects) XML&#8217;e d\u00f6n\u00fc\u015ft\u00fcrmesini ve tersini yapmas\u0131n\u0131 sa\u011flar. Bu sayede, Spring&#8217;in otomatik i\u00e7erik anla\u015fmas\u0131 mekanizmas\u0131 XML format\u0131n\u0131 da destekleyebilir.<\/p>\n<h4>Proje Yap\u0131s\u0131<\/h4>\n<p>Tipik bir Spring Boot projesi a\u015fa\u011f\u0131daki gibi bir yap\u0131ya sahip olacakt\u0131r:<\/p>\n<pre><code class=\"language-\">src\/main\/java\/com\/example\/springrestxmljson\n\u251c\u2500\u2500 SpringRestXmlJsonApplication.java  (Ana uygulama s\u0131n\u0131f\u0131)\n\u251c\u2500\u2500 model\/\n\u2502   \u2514\u2500\u2500 Product.java                   (Veri modeli)\n\u2514\u2500\u2500 controller\/\n    \u2514\u2500\u2500 ProductController.java         (REST Controller)<\/code><\/pre>\n<h3>Model S\u0131n\u0131f\u0131 Olu\u015fturma<\/h3>\n<p>RESTful servislerin temel amac\u0131, belirli kaynaklar \u00fczerindeki i\u015flemleri (olu\u015fturma, okuma, g\u00fcncelleme, silme) ger\u00e7ekle\u015ftirmektir. Bu kaynaklar\u0131 temsil etmek i\u00e7in basit Java s\u0131n\u0131flar\u0131 (POJO&#8217;lar) kullan\u0131l\u0131r. \u00d6rne\u011fin, bir \u00fcr\u00fcn kayna\u011f\u0131n\u0131 temsil eden <code>Product<\/code> s\u0131n\u0131f\u0131 olu\u015fturabiliriz.<\/p>\n<pre><code class=\"language-java\">package com.example.springrestxmljson.model;\n\nimport com.fasterxml.jackson.annotation.JsonProperty;\nimport com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty;\nimport com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlRootElement;\n\nimport java.io.Serializable;\nimport java.util.Objects;\n\n\/\/ XML i\u00e7in k\u00f6k eleman ad\u0131n\u0131 belirtir\n@JacksonXmlRootElement(localName = \"product\")\npublic class Product implements Serializable {\n\n    private static final long serialVersionUID = 1L;\n\n    \/\/ XML i\u00e7in eleman ad\u0131n\u0131 belirtir\n    @JacksonXmlProperty(localName = \"id\")\n    @JsonProperty(\"id\") \/\/ JSON i\u00e7in de kullan\u0131labilir, ancak genellikle varsay\u0131lan yeterlidir\n    private Long id;\n\n    @JacksonXmlProperty(localName = \"name\")\n    @JsonProperty(\"name\")\n    private String name;\n\n    @JacksonXmlProperty(localName = \"price\")\n    @JsonProperty(\"price\")\n    private double price;\n\n    @JacksonXmlProperty(localName = \"description\")\n    @JsonProperty(\"description\")\n    private String description;\n\n    \/\/ Varsay\u0131lan kurucu metot (Jackson i\u00e7in gereklidir)\n    public Product() {\n    }\n\n    public Product(Long id, String name, double price, String description) {\n        this.id = id;\n        this.name = name;\n        this.price = price;\n        this.description = description;\n    }\n\n    \/\/ Getter ve Setter metotlar\u0131\n    public Long getId() {\n        return id;\n    }\n\n    public void setId(Long id) {\n        this.id = id;\n    }\n\n    public String getName() {\n        return name;\n    }\n\n    public void setName(String name) {\n        this.name = name;\n    }\n\n    public double getPrice() {\n        return price;\n    }\n\n    public void setPrice(double price) {\n        this.price = price;\n    }\n\n    public String getDescription() {\n        return description;\n    }\n\n    public void setDescription(String description) {\n        this.description = description;\n    }\n\n    @Override\n    public boolean equals(Object o) {\n        if (this == o) return true;\n        if (o == null || getClass() != o.getClass()) return false;\n        Product product = (Product) o;\n        return Double.compare(product.price, price) == 0 && Objects.equals(id, product.id) && Objects.equals(name, product.name) && Objects.equals(description, product.description);\n    }\n\n    @Override\n    public int hashCode() {\n        return Objects.hash(id, name, price, description);\n    }\n\n    @Override\n    public String toString() {\n        return \"Product{\" +\n               \"id=\" + id +\n               \", name='\" + name + '\\'' +\n               \", price=\" + price +\n               \", description='\" + description + '\\'' +\n               '}';\n    }\n}<\/code><\/pre>\n<p>Yukar\u0131daki <code>Product<\/code> s\u0131n\u0131f\u0131, <code>Serializable<\/code> aray\u00fcz\u00fcn\u00fc uygulayarak nesnenin serile\u015ftirilebilir oldu\u011funu belirtir. <code>JacksonXmlRootElement<\/code> ve <code>JacksonXmlProperty<\/code> anotasyonlar\u0131, bu s\u0131n\u0131f\u0131n XML&#8217;e d\u00f6n\u00fc\u015ft\u00fcr\u00fcl\u00fcrken nas\u0131l bir yap\u0131ya sahip olaca\u011f\u0131n\u0131 Jackson k\u00fct\u00fcphanesine bildirir. JSON i\u00e7in <code>JsonProperty<\/code> de kullan\u0131labilir ancak genellikle alan adlar\u0131 do\u011frudan kullan\u0131ld\u0131\u011f\u0131 i\u00e7in zorunlu de\u011fildir.<\/p>\n<h3>REST Controller Olu\u015fturma<\/h3>\n<p>Spring&#8217;de RESTful servisler olu\u015fturmak i\u00e7in <code>@RestController<\/code> anotasyonu kullan\u0131l\u0131r. Bu anotasyon, bir s\u0131n\u0131f\u0131n hem <code>@Controller<\/code> hem de <code>@ResponseBody<\/code> oldu\u011funu belirtir, yani y\u00f6ntemlerinin do\u011frudan HTTP yan\u0131t g\u00f6vdesine serile\u015ftirilmesi gereken verileri d\u00f6nd\u00fcrd\u00fc\u011f\u00fc anlam\u0131na gelir. <code>@RequestMapping<\/code> anotasyonu ise, bir s\u0131n\u0131f veya y\u00f6ntemin hangi URL yollar\u0131na yan\u0131t verece\u011fini tan\u0131mlar.<\/p>\n<p>A\u015fa\u011f\u0131da, \u00fcr\u00fcnler \u00fczerinde CRUD (Create, Read, Update, Delete) operasyonlar\u0131n\u0131 ger\u00e7ekle\u015ftiren bir <code>ProductController<\/code> \u00f6rne\u011fi verilmi\u015ftir. Bu \u00f6rnek, hem JSON hem de XML formatlar\u0131nda veri al\u0131\u015fveri\u015fini destekleyecektir.<\/p>\n<pre><code class=\"language-java\">package com.example.springrestxmljson.controller;\n\nimport com.example.springrestxmljson.model.Product;\nimport jakarta.annotation.PostConstruct;\nimport org.springframework.http.HttpStatus;\nimport org.springframework.http.MediaType;\nimport org.springframework.http.ResponseEntity;\nimport org.springframework.web.bind.annotation.*;\n\nimport java.util.ArrayList;\nimport java.util.List;\nimport java.util.Optional;\nimport java.util.stream.Collectors;\n\n@RestController\n@RequestMapping(\"\/api\/products\") \/\/ T\u00fcm endpoint'ler bu temel yolla ba\u015flayacak\npublic class ProductController {\n\n    private List<Product> products = new ArrayList<>();\n\n    \/\/ Uygulama ba\u015flat\u0131ld\u0131\u011f\u0131nda baz\u0131 \u00f6rnek veriler ekleyelim\n    @PostConstruct\n    public void init() {\n        products.add(new Product(1L, \"Laptop\", 1200.00, \"G\u00fc\u00e7l\u00fc bir diz\u00fcst\u00fc bilgisayar\"));\n        products.add(new Product(2L, \"Mouse\", 25.00, \"Kablosuz optik fare\"));\n        products.add(new Product(3L, \"Keyboard\", 75.00, \"Mekanik oyun klavyesi\"));\n    }\n\n    \/\/ T\u00fcm \u00fcr\u00fcnleri listeleme (GET)\n    \/\/ Hem JSON hem de XML format\u0131nda yan\u0131t verebilir\n    @GetMapping(produces = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE})\n    public ResponseEntity<List<Product>> getAllProducts() {\n        return ResponseEntity.ok(products);\n    }\n\n    \/\/ Belirli bir \u00fcr\u00fcn\u00fc ID'ye g\u00f6re getirme (GET)\n    \/\/ Hem JSON hem de XML format\u0131nda yan\u0131t verebilir\n    @GetMapping(value = \"\/{id}\", produces = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE})\n    public ResponseEntity<Product> getProductById(@PathVariable Long id) {\n        Optional<Product> product = products.stream()\n                                            .filter(p -> p.getId().equals(id))\n                                            .findFirst();\n        return product.map(ResponseEntity::ok)\n                      .orElse(ResponseEntity.notFound().build());\n    }\n\n    \/\/ Yeni bir \u00fcr\u00fcn olu\u015fturma (POST)\n    \/\/ Hem JSON hem de XML format\u0131nda veri kabul edebilir ve yan\u0131t verebilir\n    @PostMapping(consumes = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE},\n                 produces = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE})\n    public ResponseEntity<Product> createProduct(@RequestBody Product product) {\n        \/\/ Yeni bir ID ata\n        Long newId = products.stream().mapToLong(Product::getId).max().orElse(0L) + 1;\n        product.setId(newId);\n        products.add(product);\n        return ResponseEntity.status(HttpStatus.CREATED).body(product);\n    }\n\n    \/\/ Mevcut bir \u00fcr\u00fcn\u00fc g\u00fcncelleme (PUT)\n    \/\/ Hem JSON hem de XML format\u0131nda veri kabul edebilir ve yan\u0131t verebilir\n    @PutMapping(value = \"\/{id}\", consumes = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE},\n                produces = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE})\n    public ResponseEntity<Product> updateProduct(@PathVariable Long id, @RequestBody Product updatedProduct) {\n        Optional<Product> existingProductOpt = products.stream()\n                                                      .filter(p -> p.getId().equals(id))\n                                                      .findFirst();\n\n        if (existingProductOpt.isPresent()) {\n            Product existingProduct = existingProductOpt.get();\n            existingProduct.setName(updatedProduct.getName());\n            existingProduct.setPrice(updatedProduct.getPrice());\n            existingProduct.setDescription(updatedProduct.getDescription());\n            return ResponseEntity.ok(existingProduct);\n        } else {\n            \/\/ E\u011fer \u00fcr\u00fcn yoksa, yeni bir \u00fcr\u00fcn olu\u015fturmak yerine 404 d\u00f6nd\u00fcr\n            \/\/ Veya yeni bir \u00fcr\u00fcn olu\u015fturup 201 d\u00f6nd\u00fcrebilirsiniz (upsert)\n            return ResponseEntity.notFound().build();\n        }\n    }\n\n    \/\/ Bir \u00fcr\u00fcn\u00fc silme (DELETE)\n    @DeleteMapping(\"\/{id}\")\n    public ResponseEntity<Void> deleteProduct(@PathVariable Long id) {\n        boolean removed = products.removeIf(p -> p.getId().equals(id));\n        if (removed) {\n            return ResponseEntity.noContent().build(); \/\/ 204 No Content\n        } else {\n            return ResponseEntity.notFound().build();\n        }\n    }\n}<\/code><\/pre>\n<p><strong>Anotasyonlar\u0131n A\u00e7\u0131klamas\u0131:<\/strong><\/p>\n<p>*   <strong><code>@RestController<\/code><\/strong>: Bu s\u0131n\u0131f\u0131n bir REST kontrolc\u00fcs\u00fc oldu\u011funu belirtir. Spring, bu s\u0131n\u0131ftaki y\u00f6ntemleri otomatik olarak HTTP isteklerine ba\u011flar ve d\u00f6nd\u00fcr\u00fclen de\u011ferleri HTTP yan\u0131t g\u00f6vdesine serile\u015ftirir.<br \/>\n*   <strong><code>@RequestMapping(\"\/api\/products\")<\/code><\/strong>: Bu kontrolc\u00fcdeki t\u00fcm y\u00f6ntemler i\u00e7in temel URL yolunu tan\u0131mlar. \u00d6rne\u011fin, <code>\/api\/products<\/code> alt\u0131nda <code>\/<\/code> veya <code>\/{id}<\/code> gibi alt yollar tan\u0131mlanabilir.<br \/>\n*   <strong><code>@PostConstruct<\/code><\/strong>: Spring bile\u015feni ba\u015flat\u0131ld\u0131ktan sonra bu y\u00f6ntemin bir kez \u00e7al\u0131\u015ft\u0131r\u0131lmas\u0131n\u0131 sa\u011flar. \u00d6rnek verileri ba\u015flatmak i\u00e7in kullan\u0131\u015fl\u0131d\u0131r.<br \/>\n*   <strong><code>@GetMapping<\/code><\/strong>: HTTP GET isteklerini belirli bir URL yoluna e\u015fler.<br \/>\n    *   <code>produces = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE}<\/code>: Bu y\u00f6ntem, istemcinin <code>Accept<\/code> ba\u015fl\u0131\u011f\u0131na g\u00f6re hem JSON (<code>application\/json<\/code>) hem de XML (<code>application\/xml<\/code>) format\u0131nda yan\u0131t \u00fcretebilir.<br \/>\n*   <strong><code>@PostMapping<\/code><\/strong>: HTTP POST isteklerini e\u015fler.<br \/>\n    *   <code>consumes = {MediaType.APPLICATION_JSON_VALUE, MediaType.APPLICATION_XML_VALUE}<\/code>: Bu y\u00f6ntem, istemciden hem JSON (<code>application\/json<\/code>) hem de XML (<code>application\/xml<\/code>) format\u0131nda veri kabul edebilir. \u0130stemcinin <code>Content-Type<\/code> ba\u015fl\u0131\u011f\u0131na g\u00f6re veri ayr\u0131\u015ft\u0131r\u0131l\u0131r.<br \/>\n    *   <code>@RequestBody Product product<\/code>: \u0130stemciden gelen HTTP iste\u011finin g\u00f6vdesindeki veriyi <code>Product<\/code> nesnesine ba\u011flar.<br \/>\n*   <strong><code>@PutMapping<\/code><\/strong>: HTTP PUT isteklerini e\u015fler. Genellikle mevcut bir kayna\u011f\u0131 g\u00fcncellemek i\u00e7in kullan\u0131l\u0131r. <code>consumes<\/code> ve <code>produces<\/code> nitelikleri POST ile benzer \u015fekilde \u00e7al\u0131\u015f\u0131r.<br \/>\n*   <strong><code>@DeleteMapping<\/code><\/strong>: HTTP DELETE isteklerini e\u015fler. Bir kayna\u011f\u0131 silmek i\u00e7in kullan\u0131l\u0131r.<br \/>\n*   <strong><code>@PathVariable Long id<\/code><\/strong>: URL yolundaki <code>{id}<\/code> gibi bir yer tutucudan de\u011feri al\u0131r ve <code>id<\/code> parametresine ba\u011flar.<br \/>\n*   <strong><code>ResponseEntity<T><\/code><\/strong>: Yan\u0131t g\u00f6vdesiyle birlikte HTTP durum kodunu ve ba\u015fl\u0131klar\u0131n\u0131 kontrol etmenizi sa\u011flar. <code>ResponseEntity.ok()<\/code> 200 OK, <code>ResponseEntity.status(HttpStatus.CREATED)<\/code> 201 Created, <code>ResponseEntity.notFound().build()<\/code> 404 Not Found gibi durum kodlar\u0131n\u0131 d\u00f6nd\u00fcrmek i\u00e7in kullan\u0131l\u0131r.<\/p>\n<h3>\u0130\u00e7erik Anla\u015fmas\u0131 (Content Negotiation)<\/h3>\n<p>\u0130\u00e7erik anla\u015fmas\u0131, bir istemcinin ayn\u0131 kayna\u011f\u0131n farkl\u0131 temsillerini (\u00f6rne\u011fin, JSON veya XML) talep etmesine olanak tan\u0131yan bir HTTP mekanizmas\u0131d\u0131r. Spring RESTful servislerinde bu s\u00fcre\u00e7 otomatik olarak y\u00f6netilir.<\/p>\n<p>Spring, a\u015fa\u011f\u0131daki mekanizmalar\u0131 kullanarak istemcinin hangi veri format\u0131n\u0131 tercih etti\u011fini anlamaya \u00e7al\u0131\u015f\u0131r:<\/p>\n<p>1.  <strong><code>Accept<\/code> Ba\u015fl\u0131\u011f\u0131<\/strong>: \u0130stemci, HTTP iste\u011finde <code>Accept<\/code> ba\u015fl\u0131\u011f\u0131n\u0131 g\u00f6ndererek hangi medya t\u00fcrlerini kabul etti\u011fini belirtir. \u00d6rne\u011fin:<br \/>\n    *   <code>Accept: application\/json<\/code> (JSON tercih edildi)<br \/>\n    *   <code>Accept: application\/xml<\/code> (XML tercih edildi)<br \/>\n    *   <code>Accept: application\/json, application\/xml;q=0.9<\/code> (JSON tercih edildi, XML ikinci s\u0131rada)<br \/>\n    Spring, bu ba\u015fl\u0131\u011fa bakar ve uygun <code>HttpMessageConverter<\/code>&#8216;\u0131 kullanarak yan\u0131t\u0131 istenen formatta serile\u015ftirir.<br \/>\n2.  <strong>URL Uzant\u0131lar\u0131<\/strong>: Daha eski veya belirli senaryolarda, istemciler URL&#8217;ye <code>.json<\/code> veya <code>.xml<\/code> uzant\u0131lar\u0131 ekleyerek format\u0131 belirtebilirler (\u00f6rne\u011fin, <code>\/api\/products.json<\/code> veya <code>\/api\/products.xml<\/code>). Spring Boot varsay\u0131lan olarak bu \u00f6zelli\u011fi kapatm\u0131\u015ft\u0131r, ancak <code>application.properties<\/code> dosyas\u0131nda <code>spring.mvc.contentnegotiation.favor-path-extension=true<\/code> ayar\u0131n\u0131 yaparak etkinle\u015ftirilebilir. Modern API&#8217;larda <code>Accept<\/code> ba\u015fl\u0131\u011f\u0131 daha yayg\u0131n ve tercih edilen bir y\u00f6ntemdir.<br \/>\n3.  <strong><code>produces<\/code> ve <code>consumes<\/code> Nitelikleri<\/strong>: <code>@RequestMapping<\/code> (veya <code>@GetMapping<\/code>, <code>@PostMapping<\/code> vb.) anotasyonlar\u0131ndaki <code>produces<\/code> ve <code>consumes<\/code> nitelikleri, bir y\u00f6ntemin hangi medya t\u00fcrlerini \u00fcretebilece\u011fini veya t\u00fcketebilece\u011fini a\u00e7\u0131k\u00e7a belirtir. Bu, Spring&#8217;in i\u00e7erik anla\u015fmas\u0131 s\u00fcrecinde \u00f6nemli bir rol oynar.<\/p>\n<p>\u00d6rnek kontrolc\u00fcm\u00fczdeki <code>produces<\/code> ve <code>consumes<\/code> nitelikleri, servisimizin hem JSON hem de XML formatlar\u0131n\u0131 destekledi\u011fini a\u00e7\u0131k\u00e7a belirtir. Spring, gelen <code>Accept<\/code> veya <code>Content-Type<\/code> ba\u015fl\u0131klar\u0131na g\u00f6re uygun Jackson d\u00f6n\u00fc\u015ft\u00fcr\u00fcc\u00fcs\u00fcn\u00fc (JSON i\u00e7in <code>MappingJackson2HttpMessageConverter<\/code>, XML i\u00e7in <code>MappingJackson2XmlHttpMessageConverter<\/code>) se\u00e7erek veriyi otomatik olarak i\u015fler.<\/p>\n<h3>HTTP Mesaj D\u00f6n\u00fc\u015ft\u00fcr\u00fcc\u00fcler (Message Converters)<\/h3>\n<p>Spring MVC&#8217;de, HTTP iste\u011finin g\u00f6vdesindeki veriyi Java nesnelerine d\u00f6n\u00fc\u015ft\u00fcrme (deserile\u015ftirme) ve Java nesnelerini HTTP yan\u0131t\u0131n\u0131n g\u00f6vdesine d\u00f6n\u00fc\u015ft\u00fcrme (serile\u015ftirme) g\u00f6revi <code>HttpMessageConverter<\/code> aray\u00fcz\u00fcn\u00fc uygulayan s\u0131n\u0131flar taraf\u0131ndan yerine getirilir.<\/p>\n<p>Spring Boot, <code>spring-boot-starter-web<\/code> ba\u011f\u0131ml\u0131l\u0131\u011f\u0131n\u0131 ekledi\u011finizde otomatik olarak bir\u00e7ok <code>HttpMessageConverter<\/code>&#8216;\u0131 yap\u0131land\u0131r\u0131r:<\/p>\n<p>*   <strong><code>MappingJackson2HttpMessageConverter<\/code><\/strong>: JSON verilerini Java nesnelerine ve tersine d\u00f6n\u00fc\u015ft\u00fcrmek i\u00e7in Jackson k\u00fct\u00fcphanesini kullan\u0131r. Bu, <code>application\/json<\/code> medya t\u00fcr\u00fcn\u00fc i\u015fler.<br \/>\n*   <strong><code>MappingJackson2XmlHttpMessageConverter<\/code><\/strong>: <code>jackson-dataformat-xml<\/code> ba\u011f\u0131ml\u0131l\u0131\u011f\u0131n\u0131 ekledi\u011finizde etkinle\u015fir. XML verilerini Java nesnelerine ve tersine d\u00f6n\u00fc\u015ft\u00fcrmek i\u00e7in Jackson XML mod\u00fcl\u00fcn\u00fc kullan\u0131r. Bu, <code>application\/xml<\/code> medya t\u00fcr\u00fcn\u00fc i\u015fler.<br \/>\n*   Di\u011fer d\u00f6n\u00fc\u015ft\u00fcr\u00fcc\u00fcler: Stringler, bayt dizileri, form verileri vb. i\u00e7in de d\u00f6n\u00fc\u015ft\u00fcr\u00fcc\u00fcler bulunur.<\/p>\n<p>Bu d\u00f6n\u00fc\u015ft\u00fcr\u00fcc\u00fclerin varl\u0131\u011f\u0131 sayesinde, geli\u015ftiricilerin serile\u015ftirme ve deserile\u015ftirme mant\u0131\u011f\u0131n\u0131 manuel olarak yazmas\u0131na gerek kalmaz. Spring, istemcinin <code>Accept<\/code> ba\u015fl\u0131\u011f\u0131na (yan\u0131t i\u00e7in) veya <code>Content-Type<\/code> ba\u015fl\u0131\u011f\u0131na (istek i\u00e7in) bakarak uygun d\u00f6n\u00fc\u015ft\u00fcr\u00fcc\u00fcy\u00fc otomatik olarak se\u00e7er.<\/p>\n<h3>Pratik \u00d6rnek Uygulama: API Test Etme<\/h3>\n<p>Uygulamam\u0131z\u0131 ba\u015flatt\u0131ktan sonra, Postman, Insomnia gibi API test ara\u00e7lar\u0131 veya <code>curl<\/code> komut sat\u0131r\u0131 arac\u0131 ile API&#8217;mizi test edebiliriz.<\/p>\n<p>Uygulamay\u0131 \u00e7al\u0131\u015ft\u0131rmak i\u00e7in <code>SpringRestXmlJsonApplication.java<\/code> dosyas\u0131n\u0131 \u00e7al\u0131\u015ft\u0131r\u0131n:<\/p>\n<pre><code class=\"language-java\">package com.example.springrestxmljson;\n\nimport org.springframework.boot.SpringApplication;\nimport org.springframework.boot.autoconfigure.SpringBootApplication;\n\n@SpringBootApplication\npublic class SpringRestXmlJsonApplication {\n\n    public static void main(String[] args) {\n        SpringApplication.run(SpringRestXmlJsonApplication.class, args);\n    }\n\n}<\/code><\/pre>\n<p>Varsay\u0131lan olarak, Spring Boot uygulamas\u0131 8080 portunda \u00e7al\u0131\u015facakt\u0131r.<\/p>\n<h4>GET \u0130stekleri<\/h4>\n<p><strong>1. T\u00fcm \u00dcr\u00fcnleri JSON Olarak Alma:<\/strong><br \/>\n*   <strong>URL:<\/strong> <code>http:\/\/localhost:8080\/api\/products<\/code><br \/>\n*   <strong>Metot:<\/strong> <code>GET<\/code><br \/>\n*   <strong>Header:<\/strong> <code>Accept: application\/json<\/code><\/p>\n<p><strong>Curl Komutu:<\/strong><\/p>\n<pre><code class=\"language-bash\">curl -X GET -H \"Accept: application\/json\" http:\/\/localhost:8080\/api\/products<\/code><\/pre>\n<p><strong>Yan\u0131t (JSON):<\/strong><\/p>\n<pre><code class=\"language-json\">[\n  {\n    \"id\": 1,\n    \"name\": \"Laptop\",\n    \"price\": 1200.0,\n    \"description\": \"G\u00fc\u00e7l\u00fc bir diz\u00fcst\u00fc bilgisayar\"\n  },\n  {\n    \"id\": 2,\n    \"name\": \"Mouse\",\n    \"price\": 25.0,\n    \"description\": \"Kablosuz optik fare\"\n  },\n  {\n    \"id\": 3,\n    \"name\": \"Keyboard\",\n    \"price\": 75.0,\n    \"description\": \"Mekanik oyun klavyesi\"\n  }\n]<\/code><\/pre>\n<p><strong>2. T\u00fcm \u00dcr\u00fcnleri XML Olarak Alma:<\/strong><br \/>\n*   <strong>URL:<\/strong> <code>http:\/\/localhost:8080\/api\/products<\/code><br \/>\n*   <strong>Metot:<\/strong> <code>GET<\/code><br \/>\n*   <strong>Header:<\/strong> <code>Accept: application\/xml<\/code><\/p>\n<p><strong>Curl Komutu:<\/strong><\/p>\n<pre><code class=\"language-bash\">curl -X GET -H \"Accept: application\/xml\" http:\/\/localhost:8080\/api\/products<\/code><\/pre>\n<p><strong>Yan\u0131t (XML):<\/strong><\/p>\n<pre><code class=\"language-xml\"><List>\n    <product>\n        <id>1<\/id>\n        <name>Laptop<\/name>\n        <price>1200.0<\/price>\n        <description>G\u00fc\u00e7l\u00fc bir diz\u00fcst\u00fc bilgisayar<\/description>\n    <\/product>\n    <product>\n        <id>2<\/id>\n        <name>Mouse<\/name>\n        <price>25.0<\/price>\n        <description>Kablosuz optik fare<\/description>\n    <\/product>\n    <product>\n        <id>3<\/id>\n        <name>Keyboard<\/name>\n        <price>75.0<\/price>\n        <description>Mekanik oyun klavyesi<\/description>\n    <\/product>\n<\/List><\/code><\/pre>\n<p><strong>Not:<\/strong> Jackson, bir <code>List<\/code> nesnesini XML&#8217;e d\u00f6n\u00fc\u015ft\u00fcr\u00fcrken varsay\u0131lan olarak bir <code><List><\/code> k\u00f6k eleman\u0131 olu\u015fturur. E\u011fer bu k\u00f6k eleman\u0131n ad\u0131n\u0131 de\u011fi\u015ftirmek isterseniz, <code>Product<\/code> s\u0131n\u0131f\u0131nda <code>@JacksonXmlRootElement<\/code> anotasyonunu kullanarak veya Jackson yap\u0131land\u0131rmas\u0131 \u00fczerinden \u00f6zelle\u015ftirebilirsiniz.<\/p>\n<p><strong>3. Belirli Bir \u00dcr\u00fcn\u00fc JSON Olarak Alma:<\/strong><br \/>\n*   <strong>URL:<\/strong> <code>http:\/\/localhost:8080\/api\/products\/1<\/code><br \/>\n*   <strong>Metot:<\/strong> <code>GET<\/code><br \/>\n*   <strong>Header:<\/strong> <code>Accept: application\/json<\/code><\/p>\n<p><strong>Curl Komutu:<\/strong><\/p>\n<pre><code class=\"language-bash\">curl -X GET -H \"Accept: application\/json\" http:\/\/localhost:8080\/api\/products\/1<\/code><\/pre>\n<p><strong>Yan\u0131t (JSON):<\/strong><\/p>\n<pre><code class=\"language-json\">{\n  \"id\": 1,\n  \"name\": \"Laptop\",\n  \"price\": 1200.0,\n  \"description\": \"G\u00fc\u00e7l\u00fc bir diz\u00fcst\u00fc bilgisayar\"\n}<\/code><\/pre>\n<h4>POST \u0130stekleri<\/h4>\n<p><strong>1. Yeni Bir \u00dcr\u00fcn JSON Olarak Olu\u015fturma:<\/strong><br \/>\n*   <strong>URL:<\/strong> <code>http:\/\/localhost:8080\/api\/products<\/code><br \/>\n*   <strong>Metot:<\/strong> <code>POST<\/code><br \/>\n*   <strong>Headers:<\/strong><br \/>\n    *   <code>Content-Type: application\/json<\/code><br \/>\n    *   <code>Accept: application\/json<\/code><br \/>\n*   <strong>Body (raw JSON):<\/strong><\/p>\n<pre><code class=\"language-json\">{\n      \"name\": \"Monitor\",\n      \"price\": 300.00,\n      \"description\": \"27 in\u00e7 4K monit\u00f6r\"\n    }<\/code><\/pre>\n<p><strong>Curl Komutu:<\/strong><\/p>\n<pre><code class=\"language-bash\">curl -X POST -H \"Content-Type: application\/json\" -H \"Accept: application\/json\" \\\n     -d '{\"name\": \"Monitor\", \"price\": 300.00, \"description\": \"27 in\u00e7 4K monit\u00f6r\"}' \\\n     http:\/\/localhost:8080\/api\/products<\/code><\/pre>\n<p><strong>Yan\u0131t (JSON &#8211; durum kodu 201 Created):<\/strong><\/p>\n<pre><code class=\"language-json\">{\n  \"id\": 4,\n  \"name\": \"Monitor\",\n  \"price\": 300.0,\n  \"description\": \"27 in\u00e7 4K monit\u00f6r\"\n}<\/code><\/pre>\n<p><strong>2. Yeni Bir \u00dcr\u00fcn XML Olarak Olu\u015fturma:<\/strong><br \/>\n*   <strong>URL:<\/strong> <code>http:\/\/localhost:8080\/api\/products<\/code><br \/>\n*   <strong>Metot:<\/strong> <code>POST<\/code><br \/>\n*   <strong>Headers:<\/strong><br \/>\n    *   <code>Content-Type: application\/xml<\/code><br \/>\n    *   <code>Accept: application\/xml<\/code><br \/>\n*   <strong>Body (raw XML):<\/strong><\/p>\n<pre><code class=\"language-xml\"><product>\n      <name>Webcam<\/name>\n      <price>50.00<\/price>\n      <description>Full HD webcam<\/description>\n    <\/product><\/code><\/pre>\n<p><strong>Curl Komutu:<\/strong><\/p>\n<pre><code class=\"language-bash\">curl -X POST -H \"Content-Type: application\/xml\" -H \"Accept: application\/xml\" \\\n     -d '<product><name>Webcam<\/name><price>50.00<\/price><description>Full HD webcam<\/description><\/product>' \\\n     http:\/\/localhost:8080\/api\/products<\/code><\/pre>\n<p><strong>Yan\u0131t (XML &#8211; durum kodu 201 Created):<\/strong><\/p>\n<pre><code class=\"language-xml\"><product>\n    <id>5<\/id>\n    <name>Webcam<\/name>\n    <price>50.0<\/price>\n    <description>Full HD webcam<\/description>\n<\/product><\/code><\/pre>\n<h4>PUT \u0130stekleri<\/h4>\n<p><strong>1. Bir \u00dcr\u00fcn\u00fc JSON Olarak G\u00fcncelleme:<\/strong><br \/>\n*   <strong>URL:<\/strong> <code>http:\/\/localhost:8080\/api\/products\/4<\/code><br \/>\n*   <strong>Metot:<\/strong> <code>PUT<\/code><br \/>\n*   <strong>Headers:<\/strong><br \/>\n    *   <code>Content-Type: application\/json<\/code><br \/>\n    *   <code>Accept: application\/json<\/code><br \/>\n*   <strong>Body (raw JSON):<\/strong><\/p>\n<pre><code class=\"language-json\">{\n      \"name\": \"UltraWide Monitor\",\n      \"price\": 550.00,\n      \"description\": \"34 in\u00e7 UltraWide QHD monit\u00f6r\"\n    }<\/code><\/pre>\n<p><strong>Curl Komutu:<\/strong><\/p>\n<pre><code class=\"language-bash\">curl -X PUT -H \"Content-Type: application\/json\" -H \"Accept: application\/json\" \\\n     -d '{\"name\": \"UltraWide Monitor\", \"price\": 550.00, \"description\": \"34 in\u00e7 UltraWide QHD monit\u00f6r\"}' \\\n     http:\/\/localhost:8080\/api\/products\/4<\/code><\/pre>\n<p><strong>Yan\u0131t (JSON &#8211; durum kodu 200 OK):<\/strong><\/p>\n<pre><code class=\"language-json\">{\n  \"id\": 4,\n  \"name\": \"UltraWide Monitor\",\n  \"price\": 550.0,\n  \"description\": \"34 in\u00e7 UltraWide QHD monit\u00f6r\"\n}<\/code><\/pre>\n<h4>DELETE \u0130stekleri<\/h4>\n<p><strong>1. Bir \u00dcr\u00fcn\u00fc Silme:<\/strong><br \/>\n*   <strong>URL:<\/strong> <code>http:\/\/localhost:8080\/api\/products\/5<\/code><br \/>\n*   <strong>Metot:<\/strong> <code>DELETE<\/code><\/p>\n<p><strong>Curl Komutu:<\/strong><\/p>\n<pre><code class=\"language-bash\">curl -X DELETE http:\/\/localhost:8080\/api\/products\/5<\/code><\/pre>\n<p><strong>Yan\u0131t (Durum kodu 204 No Content):<\/strong><br \/>\nBa\u015far\u0131l\u0131 bir silme i\u015flemi genellikle i\u00e7eriksiz bir 204 No Content yan\u0131t\u0131 d\u00f6nd\u00fcr\u00fcr.<\/p>\n<h3>Hata Y\u00f6netimi ve HTTP Durum Kodlar\u0131<\/h3>\n<p>RESTful API&#8217;ler geli\u015ftirirken, ba\u015far\u0131l\u0131 yan\u0131tlar kadar hata durumlar\u0131n\u0131 da do\u011fru bir \u015fekilde y\u00f6netmek \u00f6nemlidir. Spring, hata y\u00f6netimi i\u00e7in \u00e7e\u015fitli mekanizmalar sunar:<\/p>\n<p>*   <strong><code>ResponseEntity<\/code> Kullan\u0131m\u0131<\/strong>: Kontrolc\u00fclerimizde <code>ResponseEntity<\/code> kullanarak, yan\u0131t g\u00f6vdesiyle birlikte HTTP durum kodunu (\u00f6rne\u011fin, 200 OK, 201 Created, 404 Not Found, 500 Internal Server Error) ve ba\u015fl\u0131klar\u0131 manuel olarak ayarlayabiliriz. Bu, API&#8217;nin istemcilere anla\u015f\u0131l\u0131r geri bildirimler sa\u011flamas\u0131 i\u00e7in kritik \u00f6neme sahiptir.<br \/>\n*   <strong><code>@ResponseStatus<\/code> Anotasyonu<\/strong>: Bir y\u00f6ntemin veya \u00f6zel bir istisna s\u0131n\u0131f\u0131n\u0131n belirli bir HTTP durum koduyla sonu\u00e7lanaca\u011f\u0131n\u0131 belirtmek i\u00e7in kullan\u0131labilir.<br \/>\n*   <strong><code>@ExceptionHandler<\/code> Anotasyonu<\/strong>: Belirli istisna t\u00fcrlerini yakalamak ve \u00f6zel hata yan\u0131tlar\u0131 d\u00f6nd\u00fcrmek i\u00e7in kullan\u0131labilir. Bu, API&#8217;nizin t\u00fcm hata durumlar\u0131 i\u00e7in tutarl\u0131 bir yan\u0131t yap\u0131s\u0131na sahip olmas\u0131n\u0131 sa\u011flar. \u00d6rne\u011fin, bir kaynak bulunamad\u0131\u011f\u0131nda 404 d\u00f6nd\u00fcrmek yerine, \u00f6zel bir hata mesaj\u0131 ve kodu i\u00e7eren bir JSON\/XML yan\u0131t\u0131 d\u00f6nd\u00fcrebilirsiniz.<br \/>\n*   <strong><code>@ControllerAdvice<\/code><\/strong>: Birden \u00e7ok kontrolc\u00fcde global hata y\u00f6netimi sa\u011flamak i\u00e7in kullan\u0131l\u0131r.<\/p>\n<p>\u00d6rne\u011fimizde, <code>getProductById<\/code> metodunda \u00fcr\u00fcn bulunamad\u0131\u011f\u0131nda <code>ResponseEntity.notFound().build()<\/code> kullanarak 404 durum kodu d\u00f6nd\u00fcrd\u00fck. Bu, istemcinin beklenen kayna\u011f\u0131n bulunmad\u0131\u011f\u0131n\u0131 anlamas\u0131n\u0131 sa\u011flar.<\/p>\n<h3>En \u0130yi Uygulamalar ve \u0130pu\u00e7lar\u0131<\/h3>\n<p>RESTful API geli\u015ftirirken g\u00f6z \u00f6n\u00fcnde bulundurulmas\u0131 gereken baz\u0131 en iyi uygulamalar:<\/p>\n<p>*   <strong>API S\u00fcr\u00fcmleme<\/strong>: API&#8217;nizin zamanla de\u011fi\u015fece\u011fini varsay\u0131n. URL&#8217;lerde (\u00f6rne\u011fin, <code>\/api\/v1\/products<\/code>), <code>Accept<\/code> ba\u015fl\u0131\u011f\u0131nda (Custom Media Type) veya \u00f6zel bir HTTP ba\u015fl\u0131\u011f\u0131nda s\u00fcr\u00fcmleme yaparak geriye d\u00f6n\u00fck uyumlulu\u011fu koruyun.<br \/>\n*   <strong>G\u00fcvenlik<\/strong>: API&#8217;lerinizi g\u00fcvence alt\u0131na almak i\u00e7in kimlik do\u011frulama (Authentication) ve yetkilendirme (Authorization) mekanizmalar\u0131n\u0131 uygulay\u0131n. OAuth2, JWT (JSON Web Tokens) gibi standartlar yayg\u0131n olarak kullan\u0131l\u0131r. Spring Security bu konuda g\u00fc\u00e7l\u00fc destek sa\u011flar.<br \/>\n*   <strong>Dok\u00fcmantasyon<\/strong>: API&#8217;nizin nas\u0131l kullan\u0131laca\u011f\u0131n\u0131 a\u00e7\u0131klayan iyi bir dok\u00fcmantasyon sa\u011flay\u0131n. Swagger\/OpenAPI, API dok\u00fcmantasyonunu otomatik olarak olu\u015fturmak ve g\u00f6rselle\u015ftirmek i\u00e7in pop\u00fcler ara\u00e7lard\u0131r.<br \/>\n*   <strong>Anlaml\u0131 URL&#8217;ler<\/strong>: Kaynaklar\u0131 a\u00e7\u0131k\u00e7a tan\u0131mlayan ve hiyerar\u015fik olarak d\u00fczenlenmi\u015f URL&#8217;ler kullan\u0131n (\u00f6rne\u011fin, <code>\/api\/users\/{userId}\/orders<\/code>).<br \/>\n*   <strong>HTTP Metotlar\u0131n\u0131 Do\u011fru Kullan\u0131n<\/strong>: GET (veri alma), POST (veri olu\u015fturma), PUT (veri g\u00fcncelleme\/de\u011fi\u015ftirme), DELETE (veri silme) metotlar\u0131n\u0131 ama\u00e7lar\u0131na uygun kullan\u0131n.<br \/>\n*   <strong>HATEOAS (Hypermedia as an Engine of Application State)<\/strong>: API&#8217;nizin daha ke\u015ffedilebilir olmas\u0131n\u0131 sa\u011flamak i\u00e7in yan\u0131tlar\u0131n\u0131za ilgili kaynaklara ba\u011flant\u0131lar ekleyin. Spring HATEOAS k\u00fct\u00fcphanesi bu konuda yard\u0131mc\u0131 olur.<br \/>\n*   <strong>Do\u011frulama (Validation)<\/strong>: \u0130stemciden gelen verileri sunucu taraf\u0131nda her zaman do\u011frulay\u0131n. Spring, <code>@Valid<\/code> anotasyonu ve Bean Validation API (JSR 380) ile kolay do\u011frulama sa\u011flar.<\/p>\n<h3>Sonu\u00e7<\/h3>\n<p>Bu makalede, Spring Boot \u00e7er\u00e7evesini kullanarak hem JSON hem de XML formatlar\u0131nda veri \u00fcreten ve t\u00fcketen RESTful web servislerinin nas\u0131l geli\u015ftirilece\u011fini ayr\u0131nt\u0131l\u0131 bir \u015fekilde inceledik. REST mimarisinin temel prensiplerini, JSON ve XML veri formatlar\u0131n\u0131n \u00f6zelliklerini, Spring Boot projesi kurulumunu, model ve kontrolc\u00fc s\u0131n\u0131flar\u0131n\u0131n olu\u015fturulmas\u0131n\u0131, i\u00e7erik anla\u015fmas\u0131 mekanizmalar\u0131n\u0131 ve HTTP mesaj d\u00f6n\u00fc\u015ft\u00fcr\u00fcc\u00fclerin rol\u00fcn\u00fc ele ald\u0131k. Sa\u011flad\u0131\u011f\u0131m\u0131z pratik \u00f6rnekler ve curl komutlar\u0131 ile API&#8217;lerinizi nas\u0131l test edebilece\u011finizi g\u00f6sterdik.<\/p>\n<p>Spring Boot, <code>@RestController<\/code> ve Jackson k\u00fct\u00fcphaneleri gibi g\u00fc\u00e7l\u00fc ara\u00e7lar sayesinde, farkl\u0131 veri formatlar\u0131n\u0131 destekleyen esnek ve sa\u011flam RESTful API&#8217;ler geli\u015ftirmeyi son derece kolayla\u015ft\u0131r\u0131r. Geli\u015ftiriciler, bu yetenekleri kullanarak modern uygulamalar\u0131n ihtiya\u00e7 duydu\u011fu \u00e7e\u015fitli entegrasyon senaryolar\u0131na h\u0131zl\u0131 ve etkin bir \u015fekilde yan\u0131t verebilirler. \u0130yi tasarlanm\u0131\u015f bir REST API, uygulaman\u0131z\u0131n farkl\u0131 platformlar ve sistemlerle sorunsuz bir \u015fekilde ileti\u015fim kurmas\u0131n\u0131 sa\u011flayarak genel mimarinin esnekli\u011fini ve \u00f6l\u00e7eklenebilirli\u011fini art\u0131r\u0131r.<\/body><\/p>\n","protected":false},"excerpt":{"rendered":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber\nGiri\u015f: RESTful Web Servisleri ve Spring \u00c7er\u00e7evesi\nModern yaz\u0131l\u0131m d\u00fcnyas\u0131nda, farkl\u0131","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"csco_page_header_type":"","csco_page_load_nextpost":"","csco_page_subscribe_form":"","csco_page_contact_form":"","footnotes":""},"categories":[1],"tags":[],"class_list":{"0":"post-39027","1":"post","2":"type-post","3":"status-publish","4":"format-standard","6":"category-genel","7":"cs-entry","8":"cs-video-wrap"},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v20.5 (Yoast SEO v25.3.1) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber - Kodlar\u0131n Gizemli D\u00fcnyas\u0131<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/\" \/>\n<meta property=\"og:locale\" content=\"tr_TR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber\" \/>\n<meta property=\"og:description\" content=\"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber Giri\u015f: RESTful Web Servisleri ve Spring \u00c7er\u00e7evesi Modern yaz\u0131l\u0131m d\u00fcnyas\u0131nda, farkl\u0131\" \/>\n<meta property=\"og:url\" content=\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/\" \/>\n<meta property=\"og:site_name\" content=\"Kodlar\u0131n Gizemli D\u00fcnyas\u0131\" \/>\n<meta property=\"article:published_time\" content=\"2026-02-12T16:40:56+00:00\" \/>\n<meta name=\"author\" content=\"Fatih Soysal\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Yazan:\" \/>\n\t<meta name=\"twitter:data1\" content=\"Fatih Soysal\" \/>\n\t<meta name=\"twitter:label2\" content=\"Tahmini okuma s\u00fcresi\" \/>\n\t<meta name=\"twitter:data2\" content=\"20 dakika\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/\"},\"author\":{\"name\":\"Fatih Soysal\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\"},\"headline\":\"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber\",\"datePublished\":\"2026-02-12T16:40:56+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/\"},\"wordCount\":2789,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\"},\"inLanguage\":\"tr\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#respond\"]}],\"copyrightYear\":\"2026\",\"copyrightHolder\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/\",\"name\":\"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber - Kodlar\u0131n Gizemli D\u00fcnyas\u0131\",\"isPartOf\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#website\"},\"datePublished\":\"2026-02-12T16:40:56+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#breadcrumb\"},\"inLanguage\":\"tr\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Anasayfa\",\"item\":\"https:\/\/fatihsoysal.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#website\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/\",\"name\":\"Fatihsoysal.com\",\"description\":\"Blog - Yaz\u0131l\u0131m D\u00fcnyas\u0131 Tecr\u00fcbelerim\",\"publisher\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/fatihsoysal.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"tr\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1\",\"name\":\"Fatih Soysal\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"tr\",\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png\",\"contentUrl\":\"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png\",\"width\":512,\"height\":512,\"caption\":\"Fatih Soysal\"},\"logo\":{\"@id\":\"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/\"},\"description\":\"Kullan\u0131m ve kodlama m\u00fckemmeliyetini odak alan uygulamalar olu\u015fturma deneyimine sahip, profesyonel olarak 15+ y\u0131l \u00fczeri deneyime sahip bir yaz\u0131l\u0131m m\u00fchendisi.\",\"url\":\"https:\/\/fatihsoysal.com\/blog\/author\/fatihsoysal\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber - Kodlar\u0131n Gizemli D\u00fcnyas\u0131","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:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/","og_locale":"tr_TR","og_type":"article","og_title":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber","og_description":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber Giri\u015f: RESTful Web Servisleri ve Spring \u00c7er\u00e7evesi Modern yaz\u0131l\u0131m d\u00fcnyas\u0131nda, farkl\u0131","og_url":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/","og_site_name":"Kodlar\u0131n Gizemli D\u00fcnyas\u0131","article_published_time":"2026-02-12T16:40:56+00:00","author":"Fatih Soysal","twitter_card":"summary_large_image","twitter_misc":{"Yazan:":"Fatih Soysal","Tahmini okuma s\u00fcresi":"20 dakika"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#article","isPartOf":{"@id":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/"},"author":{"name":"Fatih Soysal","@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1"},"headline":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber","datePublished":"2026-02-12T16:40:56+00:00","mainEntityOfPage":{"@id":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/"},"wordCount":2789,"commentCount":0,"publisher":{"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1"},"inLanguage":"tr","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#respond"]}],"copyrightYear":"2026","copyrightHolder":{"@id":"https:\/\/fatihsoysal.com\/blog\/#organization"}},{"@type":"WebPage","@id":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/","url":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/","name":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber - Kodlar\u0131n Gizemli D\u00fcnyas\u0131","isPartOf":{"@id":"https:\/\/fatihsoysal.com\/blog\/#website"},"datePublished":"2026-02-12T16:40:56+00:00","breadcrumb":{"@id":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#breadcrumb"},"inLanguage":"tr","potentialAction":[{"@type":"ReadAction","target":["https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/fatihsoysal.com\/blog\/spring-rest-xml-ve-json-ornekleri-ile-kapsamli-rehber\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Anasayfa","item":"https:\/\/fatihsoysal.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Spring REST XML ve JSON \u00d6rnekleri ile Kapsaml\u0131 Rehber"}]},{"@type":"WebSite","@id":"https:\/\/fatihsoysal.com\/blog\/#website","url":"https:\/\/fatihsoysal.com\/blog\/","name":"Fatihsoysal.com","description":"Blog - Yaz\u0131l\u0131m D\u00fcnyas\u0131 Tecr\u00fcbelerim","publisher":{"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/fatihsoysal.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"tr"},{"@type":["Person","Organization"],"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/002a254750921dcfd568a99e48240dd1","name":"Fatih Soysal","image":{"@type":"ImageObject","inLanguage":"tr","@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png","contentUrl":"https:\/\/fatihsoysal.com\/blog\/wp-content\/uploads\/2024\/04\/cropped-replicate-prediction-3kgg1hgjn5rgp0cf0p5tr0jw7w-1.png","width":512,"height":512,"caption":"Fatih Soysal"},"logo":{"@id":"https:\/\/fatihsoysal.com\/blog\/#\/schema\/person\/image\/"},"description":"Kullan\u0131m ve kodlama m\u00fckemmeliyetini odak alan uygulamalar olu\u015fturma deneyimine sahip, profesyonel olarak 15+ y\u0131l \u00fczeri deneyime sahip bir yaz\u0131l\u0131m m\u00fchendisi.","url":"https:\/\/fatihsoysal.com\/blog\/author\/fatihsoysal\/"}]}},"yoast_meta":{"yoast_wpseo_title":"","yoast_wpseo_metadesc":"","yoast_wpseo_canonical":""},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/posts\/39027","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/comments?post=39027"}],"version-history":[{"count":1,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/posts\/39027\/revisions"}],"predecessor-version":[{"id":39028,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/posts\/39027\/revisions\/39028"}],"wp:attachment":[{"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/media?parent=39027"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/categories?post=39027"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fatihsoysal.com\/blog\/wp-json\/wp\/v2\/tags?post=39027"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}