missions api2

This commit is contained in:
alma 2025-05-06 17:39:21 +02:00
parent b4188003e1
commit 8b99b7df05

View File

@ -30,13 +30,14 @@ export class OutlineService {
try {
// Create a collection in Outline based on the mission
// Note: According to Outline API, setting permission to "private" makes it private
// Note: According to error message, valid permission values are 'read', 'read_write', 'admin'
// We'll use private: true to make it private
const payload = {
name: collectionName,
description: mission.description || 'Mission documentation',
color: '#4f46e5', // Indigo color as default
permission: "private", // This is the correct way to make it private
private: true // Keep this for backward compatibility
permission: "read_write", // This should be one of the allowed values
private: true // This is what actually makes it private
};
console.log('Sending to Outline API:', JSON.stringify(payload, null, 2));