Make sales invoice from sales order id by api but not save

i am trying to make sales invoice from sales order id by api but not save the code is :
POST http://{url}/api/method/erpnext.selling.doctype.sales_order.sales_order.make_sales_invoice

#body json
{
“source_name”: “SAL-ORD-2023-00006”
}
the answer is :
{
“message”: {
“owner”: “demo@techniaa.com”,
“idx”: 0,
“docstatus”: 0,
“naming_series”: “ACC-SINV-.YYYY.-”,
“customer”: “Estone Fair”,
“customer_name”: “Estone Fair”,
“is_pos”: 0,
“is_consolidated”: 0,
“is_return”: 0,
“is_debit_note”: 0,
“update_billed_amount_in_sales_order”: 0,
“company”: “ALWAHA CO”,
“company_tax_id”: “12345”,
“posting_date”: “2023-05-16”,
“posting_time”: “00:41:20.932473”,
“set_posting_time”: 0,
“due_date”: “2023-05-16”,
“po_no”: “”,
“territory”: “Turkey”,
“shipping_address_name”: “”,
“company_trn”: “12345”,
“currency”: “USD”,
“conversion_rate”: 3.748533,
“selling_price_list”: “Standard Selling”,
“price_list_currency”: “TRY”,
“plc_conversion_rate”: 0.190534,
“ignore_pricing_rule”: 1,
“update_stock”: 0,
“total_billing_amount”: 0.0,
“total_billing_hours”: 0.0,
“total_qty”: 100.0,
“base_total”: 37485.33,
“base_net_total”: 37485.33,
“total_net_weight”: 0.0,
“total”: 10000.0,
“net_total”: 10000.0,
“tax_category”: “”,
“base_total_taxes_and_charges”: 0.0,
“total_taxes_and_charges”: 0.0,
“loyalty_points”: 0,
“loyalty_amount”: 0.0,
“redeem_loyalty_points”: 0,
“apply_discount_on”: “Grand Total”,
“base_discount_amount”: 0.0,
“additional_discount_percentage”: 0.0,
“discount_amount”: 0.0,
“base_grand_total”: 37485.33,
“base_rounding_adjustment”: 0.0,
“base_rounded_total”: 37485.33,
“base_in_words”: “SAR Thirty Seven Thousand, Four Hundred And Eighty Five and Thirty Three Halala only.”,
“grand_total”: 10000.0,
“rounding_adjustment”: 0.0,
“rounded_total”: 10000.0,
“in_words”: “USD Ten Thousand only.”,
“total_advance”: 0.0,
“outstanding_amount”: 37485.33,
“disable_rounded_total”: 0,
“write_off_amount”: 0.0,
“base_write_off_amount”: 0.0,
“write_off_outstanding_amount_automatically”: 0,
“allocate_advances_automatically”: 0,
“ignore_default_payment_terms_template”: 0,
“base_paid_amount”: 0.0,
“paid_amount”: 0.0,
“base_change_amount”: 0.0,
“change_amount”: 0.0,
“letter_head”: “SUPER COMPANY”,
“group_same_items”: 0,
“vat_emirate”: “”,
“tourist_tax_return”: 0.0,
“language”: “en-US”,
“status”: “Draft”,
“customer_group”: “Individual”,
“is_internal_customer”: 0,
“is_discounted”: 0,
“debit_to”: “1310 - مدينون - AAA”,
“party_account_currency”: “SAR”,
“is_opening”: “No”,
“c_form_applicable”: “No”,
“amount_eligible_for_commission”: 37485.33,
“commission_rate”: 0.0,
“total_commission”: 0.0,
“doctype”: “Sales Invoice”,
“items”: [
{
“owner”: “demo@techniaa.com”,
“parentfield”: “items”,
“parenttype”: “Sales Invoice”,
“idx”: 1,
“docstatus”: 0,
“item_code”: “0001”,
“item_name”: “Professional services _ UX Design”,
“description”: “Professional services _ UX Design”,
“tax_rate”: 0.0,
“tax_amount”: 0.0,
“total_amount”: 0.0,
“is_zero_rated”: 0,
“is_exempt”: 0,
“item_group”: “Services”,
“image”: “”,
“qty”: 100.0,
“stock_uom”: “Hour”,
“uom”: “Hour”,
“conversion_factor”: 1.0,
“stock_qty”: 100.0,
“price_list_rate”: 0.0,
“base_price_list_rate”: 0.0,
“margin_type”: “”,
“margin_rate_or_amount”: 0.0,
“rate_with_margin”: 0.0,
“discount_percentage”: 0.0,
“discount_amount”: 0.0,
“base_rate_with_margin”: 0.0,
“rate”: 100.0,
“amount”: 10000.0,
“base_rate”: 374.85,
“base_amount”: 37485.33,
“stock_uom_rate”: 0.0,
“is_free_item”: 0,
“grant_commission”: 1,
“net_rate”: 100.0,
“net_amount”: 10000.0,
“base_net_rate”: 374.85,
“base_net_amount”: 37485.33,
“delivered_by_supplier”: 0,
“income_account”: “4110 - مبيعات - AAA”,
“is_fixed_asset”: 0,
“expense_account”: “5111 - تكلفة البضاعة المباعة - AAA”,
“enable_deferred_revenue”: 0,
“weight_per_unit”: 0.0,
“total_weight”: 0.0,
“warehouse”: “مخازن - AAA”,
“incoming_rate”: 0.0,
“allow_zero_valuation_rate”: 0,
“item_tax_rate”: “{}”,
“actual_batch_qty”: 0.0,
“actual_qty”: 0.0,
“sales_order”: “SAL-ORD-2023-00006”,
“so_detail”: “25e2df378a”,
“delivered_qty”: 0.0,
“cost_center”: “رئيسي - AAA”,
“page_break”: 0,
“doctype”: “Sales Invoice Item”,
“__islocal”: 1,
“__unsaved”: 1
}
],
“pricing_rules”: [],
“packed_items”: [],
“timesheets”: [],
“taxes”: [],
“advances”: [],
“payment_schedule”: [],
“payments”: [],
“sales_team”: [],
“__islocal”: 1,
“__onload”: {
“load_after_mapping”: true
},
“__unsaved”: 1
}
}

but not save i tried to show all sales invoice by

GET http://{url}/api/resource/Sales Invoice

not show any new id why ?

This method returns the data needed for the sales invoice. You still need to create the Sales Invoice resource with that as the data body with POST /resource/Sales Invoice

You can append submit_on_creation and doctype if you want to create it submitted