API · v1 · estable
CODEMETA OSDeveloper Center
ES
Abrir la consola
Entidad · course_charges

Course Charge Schema

ID del esquema
course_charge
Colección
course_charges
Permisos
  • Leercourse_charge_view
  • Crearcourse_charge_view
  • Modificarcourse_charge_refund
  • Eliminarcourse_charge_refund
Relaciones

Campos

Course Charge Schema

course_charges4 permisos

Billing record for one cross-tenant enrollment in a paid shared course

enrollmentIduuidobligatorio
solo lectura
courseIduuidobligatorio→ course
solo lectura
shareIduuidobligatorio
solo lectura
consumerTenantIduuidobligatorio

Customer-tenant the learner belongs to (the bill recipient).

solo lectura
consumerUserIduuidobligatorio

User in the customer-tenant who triggered the enrollment.

solo lectura
grossAmountCentsintegerobligatorio

Gross charge in EUR cents (or `currency` cents) — what the customer owes.

≥ 0solo lectura
netAmountCentsintegeropcional

Net of VAT.

≥ 0solo lectura
taxAmountCentsintegeropcional

VAT amount.

≥ 0solo lectura
taxRatePercentnumberopcional
0 – 100Valor por defecto: 19
currencystringobligatorio
Valor por defecto: "EUR"
mspNetAmountCentsintegerobligatorio

What the MSP keeps after Codemeta platform fee.

≥ 0solo lectura
codemetaPlatformFeeCentsintegerobligatorio

Codemeta platform fee deducted from the charge.

≥ 0solo lectura
codemetaPlatformFeePercentnumberopcional

Percentage of gross taken as platform fee at charge creation time.

0 – 100Valor por defecto: 10solo lectura
statusstringobligatorio
pendinginvoicedpaidrefundedfailed
Valor por defecto: "pending"
billingModestringobligatorio

external: settled between the tenants outside Codemeta, no platform fee (ADR 1168). wholesale: aggregated into customer wholesale invoice. direct_stripe: paid in real-time via Stripe Connect.

wholesaledirect_stripeexternal
solo lectura
occurredAtdatetimeobligatorio

When the charge became applicable (= enrollment creation time).

solo lectura
invoicedAtdatetimeopcional
admite null
invoiceIduuidopcional

Wholesale invoice the charge has been bundled into.

admite null
paidAtdatetimeopcional
admite null
refundedAtdatetimeopcional
admite null
refundReasonstringopcional
máx. 500 caracteresadmite null
stripePaymentIntentIdstringopcional
solo lecturaadmite null
stripeChargeIdstringopcional
admite null
stripeRefundIdstringopcional
admite null
stripeAccountIdstringopcional

MSP Stripe Connect account that received the destination charge.

admite null
notesstringopcional
máx. 2000 caracteresadmite null

Endpoints estándar

Este recurso sigue el contrato CRUD genérico de la plataforma. Lea las convenciones sobre paginación, idempotencia, bloqueo optimista y auditoría. Los endpoints principales:

  • GET /api/v1/course_charges — Lista, paginada y filtrable
  • GET /api/v1/course_charges/<id> — Una entidad
  • POST /api/v1/course_charges — Crear
  • PATCH /api/v1/course_charges/<id> — Actualización parcial
  • DELETE /api/v1/course_charges/<id> — Eliminación lógica
  • GET /api/v1/course_charges/<id>/timeline — Auditoría y actividades

Búsqueda